From cfaa74f76175f9669eff3e0d9d050e5441aa5351 Mon Sep 17 00:00:00 2001 From: Martin Pitt Date: Tue, 6 Jul 2021 09:02:39 +0200 Subject: [PATCH] test: Fix host name lookup (#473) Our code reads /etc/hostname. Do the same in the test, as the runtime sethostname(2) (set by hostnamed) and static host name may be different. --- test/check-application | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/check-application b/test/check-application index b149d16..2a13ce3 100755 --- a/test/check-application +++ b/test/check-application @@ -25,7 +25,7 @@ class TestApplication(testlib.MachineCase): b.wait_text(".pf-c-card__title", "Starter Kit") # verify expected host name - hostname = m.execute("hostname").strip() + hostname = m.execute("cat /etc/hostname").strip() b.wait_in_text(".pf-c-alert__title", "Running on " + hostname) # change current hostname