test: Add two pixel test points
This needs a stable hostname, so we set our own at the start of the test.
This commit is contained in:
parent
7d5754872e
commit
2635dadafb
1 changed files with 6 additions and 2 deletions
|
|
@ -20,16 +20,19 @@ class TestApplication(testlib.MachineCase):
|
|||
b = self.browser
|
||||
m = self.machine
|
||||
|
||||
hostname = "starterbox"
|
||||
self.write_file("/etc/hostname", hostname)
|
||||
|
||||
self.login_and_go("/starter-kit")
|
||||
# verify expected heading
|
||||
b.wait_text(".pf-c-card__title", "Starter Kit")
|
||||
|
||||
# verify expected host name
|
||||
hostname = m.execute("hostname").strip()
|
||||
b.wait_in_text(".pf-c-alert__title", "Running on " + hostname)
|
||||
b.assert_pixels(".pf-c-card__body", "hostname")
|
||||
|
||||
# change current hostname
|
||||
self.write_file("/etc/hostname", "new-" + hostname)
|
||||
m.write("/etc/hostname", "new-" + hostname)
|
||||
# verify new hostname name
|
||||
b.wait_in_text(".pf-c-alert__title", "Running on new-" + hostname)
|
||||
|
||||
|
|
@ -57,6 +60,7 @@ class TestApplication(testlib.MachineCase):
|
|||
b.enter_page("/starter-kit")
|
||||
# page label (from js) should be translated
|
||||
b.wait_in_text(".pf-c-alert__title", "Läuft auf")
|
||||
b.assert_pixels(".pf-c-card__body", "gastgebername")
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue