Skip to content

Commit 5fe7527

Browse files
Merge pull request #393 from immutable/test/fix-device-code-auth
[DX-3561] test: fix device code auth ui test
2 parents 63c4b30 + 28fdff2 commit 5fe7527

File tree

2 files changed

+8
-2
lines changed

2 files changed

+8
-2
lines changed

sample/Tests/test/test_mac.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ def login(cls):
5757
print("Switched to new window")
5858

5959
## Device confirmation
60-
contine_button = WebDriverWait(cls.seleniumdriver, 60).until(EC.element_to_be_clickable((By.CLASS_NAME, "Button--primary")))
60+
contine_button = WebDriverWait(cls.seleniumdriver, 60).until(EC.element_to_be_clickable((SeleniumBy.XPATH, "//button[span[text()='Continue']]")))
6161
contine_button.click()
6262

6363
# Wait for email input and enter email

sample/Tests/test/test_windows_helpers.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,11 +44,17 @@ def login():
4444

4545
wait = WebDriverWait(driver, 60)
4646

47+
print("Wait for device confirmation...")
48+
contine_button = wait.until(EC.element_to_be_clickable((By.XPATH, "//button[span[text()='Continue']]")))
49+
contine_button.click()
50+
print("Confirmed device")
51+
4752
print("Wait for email input...")
4853
email_field = wait.until(EC.presence_of_element_located((By.ID, ':r1:')))
49-
print("Enter email")
54+
print("Enter email...")
5055
email_field.send_keys(EMAIL)
5156
email_field.send_keys(Keys.RETURN)
57+
print("Entered email")
5258

5359
# Wait for the OTP to arrive and page to load
5460
print("Wait for OTP...")

0 commit comments

Comments
 (0)