forked from TrueCloudLab/restic
Allow skipping the test against s3
If RESTIC_TEST_S3_REPOSITORY is not available it means we're probably running on Travis for a third-party PR, so the access credentials for S3 are not exposed.
This commit is contained in:
parent
ee68f9298b
commit
82e15dc6dc
1 changed files with 8 additions and 1 deletions
|
@ -155,8 +155,15 @@ func (env *TravisEnvironment) RunTests() error {
|
|||
"restic/backend/rest.TestBackendREST",
|
||||
"restic/backend/sftp.TestBackendSFTP",
|
||||
"restic/backend/s3.TestBackendMinio",
|
||||
"restic/backend/s3.TestBackendS3",
|
||||
}
|
||||
|
||||
// if the test s3 repository is available, make sure that the test is not skipped
|
||||
if os.Getenv("RESTIC_TEST_S3_REPOSITORY") != "" {
|
||||
ensureTests = append(ensureTests, "restic/backend/s3.TestBackendS3")
|
||||
} else {
|
||||
msg("S3 repository not available\n")
|
||||
}
|
||||
|
||||
env.env["RESTIC_TEST_DISALLOW_SKIP"] = strings.Join(ensureTests, ",")
|
||||
|
||||
if *runCrossCompile {
|
||||
|
|
Loading…
Reference in a new issue