Skip to content

Commit e33b7d3

Browse files
authored
Merge pull request #68 from UWIT-IAM/GH-67
[GH-67] update tests for DUOs slight change of a link to a button and update outdated commands
2 parents c037849 + c25b8e3 commit e33b7d3

3 files changed

Lines changed: 5 additions & 5 deletions

File tree

Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
# The poetry image is built often, so pinning to avoid breaking changes
22
FROM ghcr.io/uwit-iam/poetry:2025.04.02T012232 AS apt-base
3-
ENV ALLOW_HOSTS_MODIFICATION "1"
3+
ENV ALLOW_HOSTS_MODIFICATION="1"
44
RUN apt-get update && apt-get -y install curl jq dnsutils
55

6-
FROM apt-base as poetry-base
6+
FROM apt-base AS poetry-base
77
WORKDIR /uw-idp-tests
88
COPY poetry.lock pyproject.toml scripts/entrypoint.sh ./
99
RUN poetry install --no-root

tests/conftest.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -174,8 +174,8 @@ def duo_push(current_browser: Chrome):
174174
Select the other duo option, to get to the bypass code option
175175
"""
176176
wait = WebDriverWait(current_browser, 10)
177-
wait.until(EC.element_to_be_clickable((By.XPATH, "//a[contains(text(), 'Other options')]")))
178-
current_browser.wait_for_tag('a', 'Other options').click()
177+
wait.until(EC.element_to_be_clickable((By.XPATH, "//button[contains(text(), 'Other options')]")))
178+
current_browser.wait_for_tag('button', 'Other options').click()
179179
current_browser.wait_for_tag('b', 'Other options to log in')
180180

181181

tests/test_2fa_duo.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@ def test_remember_me_cookie(
196196
Select the other duo option, to get to the bypass code option
197197
"""
198198
wait = WebDriverWait(fresh_browser, 10)
199-
wait.until(EC.element_to_be_clickable((By.XPATH, "//a[contains(text(), 'Other options')]")))
199+
wait.until(EC.element_to_be_clickable((By.XPATH, "//button[contains(text(), 'Other options')]")))
200200
enter_duo_passcode(fresh_browser, match_service_provider=sp, select_this_is_my_device=True)
201201

202202
# go to an idp site to retrieve the shib idp cookies

0 commit comments

Comments
 (0)