Added tests to check Drivetrain on K8s
Change-Id: I86b9bbccf771cee6d6d294bb76f0c3979e269e86
Related-Prod: #PROD-29625(PROD:29625)
diff --git a/test_set/cvp-sanity/fixtures/base.py b/test_set/cvp-sanity/fixtures/base.py
index 8c5be34..4858c83 100644
--- a/test_set/cvp-sanity/fixtures/base.py
+++ b/test_set/cvp-sanity/fixtures/base.py
@@ -102,11 +102,23 @@
@pytest.fixture(scope='session')
def check_kdt(local_salt_client):
kdt_nodes_available = local_salt_client.test_ping(
- tgt="I@gerrit:client and I@kubernetes:pool",
+ tgt="I@gerrit:client and I@kubernetes:pool and not I@salt:master",
expr_form='compound'
)
if not kdt_nodes_available:
pytest.skip("No 'kdt' nodes found. Skipping this test...")
+ return kdt_nodes_available.keys()
+
+
+@pytest.fixture(scope='session')
+def check_kfg(local_salt_client):
+ kfg_nodes_available = local_salt_client.cmd(
+ tgt="I@kubernetes:pool and I@salt:master",
+ expr_form='compound'
+ )
+ if not kfg_nodes_available:
+ pytest.skip("No cfg-under-Kubernetes nodes found. Skipping this test...")
+ return kfg_nodes_available.keys()
@pytest.fixture(scope='session')
@@ -159,4 +171,4 @@
yield
except Exception as e:
print("print_node_version:: some error occurred: {}".format(e))
- yield
\ No newline at end of file
+ yield