Skip to content

Commit

Permalink
Merge pull request #614 from gravis/fix_go_116
Browse files Browse the repository at this point in the history
Define a new compile func for go 1.16
  • Loading branch information
riannucci committed Apr 27, 2021
2 parents 7827743 + ec8bade commit c7f53ec
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 4 deletions.
4 changes: 0 additions & 4 deletions web/server/system/shell.go
Expand Up @@ -52,10 +52,6 @@ func findGoConvey(directory, gobin, packageName, tagsArg string) Command {
return NewCommand(directory, gobin, "list", "-f", "'{{.TestImports}}{{.XTestImports}}'", tagsArg, packageName)
}

func compile(directory, gobin, tagsArg string) Command {
return NewCommand(directory, gobin, "test", "-i", tagsArg)
}

func runWithCoverage(compile, goconvey Command, coverage bool, reportPath, directory, gobin, defaultTimeout, tagsArg string, customArguments []string) Command {
if compile.Error != nil || goconvey.Error != nil {
return compile
Expand Down
7 changes: 7 additions & 0 deletions web/server/system/shell_1_16.go
@@ -0,0 +1,7 @@
// +build go1.16

package system

func compile(directory, gobin, tagsArg string) Command {
return NewCommand(directory, gobin, "test", tagsArg)
}
7 changes: 7 additions & 0 deletions web/server/system/shell_older_than_1_16.go
@@ -0,0 +1,7 @@
// +build !go1.16

package system

func compile(directory, gobin, tagsArg string) Command {
return NewCommand(directory, gobin, "test", "-i", tagsArg)
}

0 comments on commit c7f53ec

Please sign in to comment.