mirror of
https://git.sr.ht/~eliasnaur/gio
synced 2026-07-01 07:35:40 +00:00
cmd: bump gioui.org dependency, use -modfile properly on CI
A simple 'go test -modfile=<path>' won't work properly for the end-to-end tests, since they run 'go build' under the hood as well. To properly propagate the flag, we need to use GOFLAGS. Since -modfile is always relative to the current directory, we can't use it to test many packages at once, nor can we use it via 'go test ./gogio'. While at it, document this distinction in go.local.mod to prevent others getting confused like I did. Signed-off-by: Daniel Martí <mvdan@mvdan.cc>
This commit is contained in:
+2
-1
@@ -46,7 +46,8 @@ tasks:
|
||||
cd gio/cmd
|
||||
go test ./...
|
||||
go test -race ./...
|
||||
go test -modfile=go.local.mod ./...
|
||||
cd gogio # since we need -modfile to point at the parent directory
|
||||
GOFLAGS=-modfile=../go.local.mod go test
|
||||
- test_example: |
|
||||
cd gio/example
|
||||
go test -race ./...
|
||||
|
||||
@@ -1,3 +1,9 @@
|
||||
// Keep in sync with go.mod; the only difference should be the gioui.org
|
||||
// replace. To use it:
|
||||
//
|
||||
// cd gogio
|
||||
// GOFLAGS=-modfile=../go.local.mod go test
|
||||
|
||||
module gioui.org/cmd
|
||||
|
||||
go 1.13
|
||||
|
||||
+1
-1
@@ -3,7 +3,7 @@ module gioui.org/cmd
|
||||
go 1.13
|
||||
|
||||
require (
|
||||
gioui.org v0.0.0-20200503190452-8d9612f9aa46
|
||||
gioui.org v0.0.0-20200510064036-c2cbcee78de0
|
||||
github.com/chromedp/cdproto v0.0.0-20191114225735-6626966fbae4
|
||||
github.com/chromedp/chromedp v0.5.2
|
||||
golang.org/x/image v0.0.0-20190802002840-cff245a6509b
|
||||
|
||||
+2
-2
@@ -1,6 +1,6 @@
|
||||
dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU=
|
||||
gioui.org v0.0.0-20200503190452-8d9612f9aa46 h1:7OFSBlHlymqJPrX54xUKnattrlsTxmVbTZwtFbG+kgU=
|
||||
gioui.org v0.0.0-20200503190452-8d9612f9aa46/go.mod h1:AHI9rFr6AEEHCb8EPVtb/p5M+NMJRKH58IOp8O3Je04=
|
||||
gioui.org v0.0.0-20200510064036-c2cbcee78de0 h1:8QYEZvEzu7Jtb6QGNRCV5/innPTrafeidxdcHZ67p6U=
|
||||
gioui.org v0.0.0-20200510064036-c2cbcee78de0/go.mod h1:AHI9rFr6AEEHCb8EPVtb/p5M+NMJRKH58IOp8O3Je04=
|
||||
github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802 h1:1BDTz0u9nC3//pOCMdNH+CiXJVYJh5UQNCOBG7jbELc=
|
||||
github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo=
|
||||
github.com/chromedp/cdproto v0.0.0-20191114225735-6626966fbae4 h1:QD3KxSJ59L2lxG6MXBjNHxiQO2RmxTQ3XcK+wO44WOg=
|
||||
|
||||
Reference in New Issue
Block a user