From 646fe183bf7bdd2217c40fef5223516115a98571 Mon Sep 17 00:00:00 2001 From: Chris Hoffman Date: Fri, 19 Oct 2018 11:35:21 -0400 Subject: [PATCH] Only run cassandra test with VAULT_ACC set --- plugins/database/cassandra/cassandra_test.go | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/plugins/database/cassandra/cassandra_test.go b/plugins/database/cassandra/cassandra_test.go index 2eb47b30b2..1705117b61 100644 --- a/plugins/database/cassandra/cassandra_test.go +++ b/plugins/database/cassandra/cassandra_test.go @@ -73,7 +73,7 @@ func prepareCassandraTestContainer(t *testing.T) (func(), string, int) { } func TestCassandra_Initialize(t *testing.T) { - if os.Getenv("TRAVIS") != "true" { + if os.Getenv("VAULT_ACC") == "" { t.SkipNow() } cleanup, address, port := prepareCassandraTestContainer(t) @@ -118,7 +118,7 @@ func TestCassandra_Initialize(t *testing.T) { } func TestCassandra_CreateUser(t *testing.T) { - if os.Getenv("TRAVIS") != "true" { + if os.Getenv("VAULT_ACC") == "" { t.SkipNow() } cleanup, address, port := prepareCassandraTestContainer(t) @@ -158,7 +158,7 @@ func TestCassandra_CreateUser(t *testing.T) { } func TestMyCassandra_RenewUser(t *testing.T) { - if os.Getenv("TRAVIS") != "true" { + if os.Getenv("VAULT_ACC") == "" { t.SkipNow() } cleanup, address, port := prepareCassandraTestContainer(t) @@ -203,7 +203,7 @@ func TestMyCassandra_RenewUser(t *testing.T) { } func TestCassandra_RevokeUser(t *testing.T) { - if os.Getenv("TRAVIS") != "true" { + if os.Getenv("VAULT_ACC") == "" { t.SkipNow() } cleanup, address, port := prepareCassandraTestContainer(t) @@ -253,7 +253,7 @@ func TestCassandra_RevokeUser(t *testing.T) { } func TestCassandra_RotateRootCredentials(t *testing.T) { - if os.Getenv("TRAVIS") != "true" { + if os.Getenv("VAULT_ACC") == "" { t.SkipNow() } cleanup, address, port := prepareCassandraTestContainer(t)