tests/image: add path constants for Travis CI
The new set of constants allows to run the tests on Travis. The tests must be build by: go build -tags travis ./cmd/osbuild-image-tests
This commit is contained in:
parent
03ae0007af
commit
dc9c82fd96
2 changed files with 26 additions and 0 deletions
24
cmd/osbuild-image-tests/constants-travis.go
Normal file
24
cmd/osbuild-image-tests/constants-travis.go
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
// +build travis
|
||||
|
||||
package main
|
||||
|
||||
import "os/exec"
|
||||
|
||||
func getOsbuildCommand(store string) *exec.Cmd {
|
||||
cmd := exec.Command(
|
||||
"python3",
|
||||
"-m", "osbuild",
|
||||
"--libdir", ".",
|
||||
"--store", store,
|
||||
"--json",
|
||||
"-",
|
||||
)
|
||||
cmd.Dir = "osbuild"
|
||||
return cmd
|
||||
}
|
||||
|
||||
var imageInfoPath = "tools/image-info"
|
||||
var privateKeyPath = "test/keyring/id_rsa"
|
||||
var testCasesDirectoryPath = "test/cases"
|
||||
var userDataPath = "test/cloud-init/user-data"
|
||||
var metaDataPath = "test/cloud-init/meta-data"
|
||||
|
|
@ -1,3 +1,5 @@
|
|||
// +build !travis
|
||||
|
||||
package main
|
||||
|
||||
import "os/exec"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue