mirror of
https://github.com/kata-containers/kata-containers.git
synced 2025-04-28 03:42:09 +00:00
Run tests for the s390x build
It turns out it is possible to run the unit tests for the s390x build on travis by renaming the s390x specific files, so that their inclusion in the build is determined only by tags and not by filename, and by introducing a new tag s390x_test that we can use to force their inclusion into a build by using this tag. The .travis file is then updated to include the line go test --tags s390x_test ./... This creates a build on travis that includes the s390x specific files and runs the unit tests. Signed-off-by: Mark Ryan <mark.d.ryan@intel.com>
This commit is contained in:
parent
09923e8ed7
commit
d6173077f1
@ -21,3 +21,4 @@ script:
|
||||
- $GOPATH/bin/goveralls -v -service=travis-ci
|
||||
- gometalinter --tests --vendor --disable-all --enable=misspell --enable=vet --enable=ineffassign --enable=gofmt --enable=gocyclo --cyclo-over=15 --enable=golint --enable=errcheck --enable=deadcode --enable=staticcheck -enable=gas ./...
|
||||
- GOARCH=s390x go install ./...
|
||||
- go test --tags s390x_test ./...
|
||||
|
@ -1,4 +1,4 @@
|
||||
// +build !s390x
|
||||
// +build !s390x,!s390x_test
|
||||
|
||||
/*
|
||||
// Copyright contributors to the Virtual Machine Manager for Go project
|
||||
|
@ -1,4 +1,4 @@
|
||||
// +build !s390x
|
||||
// +build !s390x,!s390x_test
|
||||
|
||||
/*
|
||||
// Copyright contributors to the Virtual Machine Manager for Go project
|
||||
|
@ -1,4 +1,4 @@
|
||||
// +build s390x
|
||||
// +build s390x s390x_test
|
||||
|
||||
/*
|
||||
// Copyright contributors to the Virtual Machine Manager for Go project
|
@ -1,4 +1,4 @@
|
||||
// +build s390x
|
||||
// +build s390x s390x_test
|
||||
|
||||
/*
|
||||
// Copyright contributors to the Virtual Machine Manager for Go project
|
Loading…
Reference in New Issue
Block a user