File tree Expand file tree Collapse file tree 2 files changed +16
-0
lines changed Expand file tree Collapse file tree 2 files changed +16
-0
lines changed Original file line number Diff line number Diff line change @@ -263,3 +263,15 @@ jobs:
263
263
submodules : false # avoid cloning ethereum/tests
264
264
script :
265
265
- go run build/ci.go purge -store gethstore/builds -days 14
266
+
267
+ # This builder executes race tests
268
+ - stage : build
269
+ if : type = cron
270
+ os : linux
271
+ dist : bionic
272
+ go : 1.17.x
273
+ env :
274
+ - GO111MODULE=on
275
+ script :
276
+ - go run build/ci.go test -race -coverage $TEST_PACKAGES
277
+
Original file line number Diff line number Diff line change @@ -282,6 +282,7 @@ func doTest(cmdline []string) {
282
282
cc = flag .String ("cc" , "" , "Sets C compiler binary" )
283
283
coverage = flag .Bool ("coverage" , false , "Whether to record code coverage" )
284
284
verbose = flag .Bool ("v" , false , "Whether to log verbosely" )
285
+ race = flag .Bool ("race" , false , "Execute the race detector" )
285
286
)
286
287
flag .CommandLine .Parse (cmdline )
287
288
@@ -302,6 +303,9 @@ func doTest(cmdline []string) {
302
303
if * verbose {
303
304
gotest .Args = append (gotest .Args , "-v" )
304
305
}
306
+ if * race {
307
+ gotest .Args = append (gotest .Args , "-race" )
308
+ }
305
309
306
310
packages := []string {"./..." }
307
311
if len (flag .CommandLine .Args ()) > 0 {
You can’t perform that action at this time.
0 commit comments