summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorMichael Abel <75477722+abelikt@users.noreply.github.com>2022-01-26 15:00:30 +0100
committerGitHub <noreply@github.com>2022-01-26 15:00:30 +0100
commit6bbcdff8de2569bfff3e1a8085c21aaf98a5d96f (patch)
treea4b249cf6594d0c07d8339853ff5e2a098cf984d /tests
parent2efb3d1e74b006aea28deb06f868c28c59b2d06c (diff)
Adopt test case to current stdout of tedge connect (#776)
* Adopt test case to current stdout of test * Update connect message to current implementation * Wait 1s to give Cumulocity time to process the certificate
Diffstat (limited to 'tests')
-rw-r--r--tests/PySys/misc_features/valid_device_id/run.py8
-rw-r--r--tests/PySys/tedge_connect/c8y_restart_bridge/run.py2
-rw-r--r--tests/PySys/tedge_connect/tedge_connect_test_positive/run.py2
3 files changed, 7 insertions, 5 deletions
diff --git a/tests/PySys/misc_features/valid_device_id/run.py b/tests/PySys/misc_features/valid_device_id/run.py
index 22544bf4..8c81f4bc 100644
--- a/tests/PySys/misc_features/valid_device_id/run.py
+++ b/tests/PySys/misc_features/valid_device_id/run.py
@@ -26,7 +26,7 @@ class ValidateValidDeviceId(BaseTest):
arguments=[self.tedge, "disconnect", "c8y"],
stdouterr="c8y_disconnect",
)
-
+
# create a custom certiticate directory for testing purpose
create_cert_dir = self.startProcess(
command=self.sudo,
@@ -40,7 +40,7 @@ class ValidateValidDeviceId(BaseTest):
arguments=["chown", "mosquitto:mosquitto", "/tmp/test-device-certs"],
stdouterr="change_owner_of_dir",
)
-
+
# set the custom certificate path
set_cert_path = self.startProcess(
command=self.sudo,
@@ -77,6 +77,8 @@ class ValidateValidDeviceId(BaseTest):
stdouterr="cert_upload",
)
+ time.sleep(1)
+
# connect to the c8y cloud
c8y_connect = self.startProcess(
command=self.sudo,
@@ -97,7 +99,7 @@ class ValidateValidDeviceId(BaseTest):
self.assertGrep("c8y_connect_test.out", "successful", contains=True)
def device_id_cleanup(self):
-
+
# disconnect the test
c8y_disconnect = self.startProcess(
command=self.sudo,
diff --git a/tests/PySys/tedge_connect/c8y_restart_bridge/run.py b/tests/PySys/tedge_connect/c8y_restart_bridge/run.py
index 0848cd8e..8d5bdcf2 100644
--- a/tests/PySys/tedge_connect/c8y_restart_bridge/run.py
+++ b/tests/PySys/tedge_connect/c8y_restart_bridge/run.py
@@ -31,7 +31,7 @@ class RestartBridge(EnvironmentC8y):
super().validate()
self.log.info("Validate")
self.assertGrep(
- "tedge_connect.out", "connection check is successful.", contains=True
+ "tedge_connect.out", "Connection check is successful.", contains=True
)
fail = "Warning: Bridge has been configured, but Cumulocity connection check failed."
self.assertGrep("tedge_connect.out", fail, contains=False)
diff --git a/tests/PySys/tedge_connect/tedge_connect_test_positive/run.py b/tests/PySys/tedge_connect/tedge_connect_test_positive/run.py
index 089e7f77..42868d4f 100644
--- a/tests/PySys/tedge_connect/tedge_connect_test_positive/run.py
+++ b/tests/PySys/tedge_connect/tedge_connect_test_positive/run.py
@@ -31,7 +31,7 @@ class TedgeConnectTestPositive(EnvironmentC8y):
super().validate()
self.log.info("Validate")
self.assertGrep(
- "tedge_connect_c8y_test_positive.out", "connection check is successful.", contains=True
+ "tedge_connect_c8y_test_positive.out", "Connection check to c8y cloud is successful.", contains=True
)
try:
id = self.device_fragment['id']