Skip to content

Commit 8d25cb8

Browse files
committed
Updates for GDM test util
Small timing change with the check_home_screen wait. Drop unnecessary steps in login_idp. Add scauto_path to misc globals.
1 parent 117ca0a commit 8d25cb8

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

sssd_test_framework/misc/globals.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,4 @@
22

33
test_venv = "/opt/test_venv"
44
test_venv_bin = f"{test_venv}/bin"
5+
scauto_path = f"{test_venv_bin}/scauto"

sssd_test_framework/utils/gdm.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
from typing import TYPE_CHECKING
99

1010
from pytest_mh import MultihostHost, MultihostUtility
11+
from ..misc.globals import scauto_path
1112

1213
if TYPE_CHECKING:
1314
from ..roles.client import Client
@@ -27,7 +28,7 @@ def __init__(self, host):
2728
super().__init__(host)
2829
self.init_completed = False
2930

30-
self.cmd = ["/opt/test_venv/bin/scauto", "gui", "--wait-time", "1", "--no-screenshot"]
31+
self.cmd = [scauto_path, "gui", "--wait-time", "1", "--no-screenshot"]
3132

3233
def teardown(self):
3334
if self.init_completed:
@@ -126,7 +127,7 @@ def check_home_screen(self) -> bool:
126127
if not self.init_completed:
127128
self.init()
128129

129-
cmd = ["/opt/test_venv/bin/scauto", "-v", "debug", "gui", "--wait-time", "5", "--no-screenshot"]
130+
cmd = [scauto_path, "-v", "debug", "gui", "--wait-time", "2", "--no-screenshot"]
130131
result = self.host.conn.exec([*cmd, "check-home-screen"], raise_on_error=False)
131132
return result.rc == 0
132133

@@ -163,8 +164,6 @@ def login_idp(self, client: Client, username: str, password: str) -> bool:
163164
client.journald.clear()
164165

165166
self.click_on("listed?")
166-
self.kb_send("tab")
167-
self.click_on("Username")
168167
self.kb_write(username)
169168
self.click_on("Log")
170169

0 commit comments

Comments
 (0)