Skip to content
This repository was archived by the owner on Jun 7, 2023. It is now read-only.

Commit 572218e

Browse files
committed
More debug guessing.
1 parent 800ba1c commit 572218e

2 files changed

Lines changed: 7 additions & 1 deletion

File tree

.github/workflows/python-package.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@ jobs:
4747
- name: Test with pytest
4848
id: pytest
4949
run: |
50+
cd runestone/activecode/test
5051
pytest
5152
5253
- uses: act10ns/slack@v1

runestone/activecode/test/test_activecode.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,10 +128,15 @@ def test_sql_activecode(selenium_utils_get):
128128
# Some hacky debug code to try and understand why this fails on Github actions.
129129
for _ in selenium_utils_get.driver.get_log("browser"):
130130
print(_)
131+
from selenium.webdriver.support.ui import WebDriverWait
132+
long_wait = WebDriverWait(selenium_utils_get.driver, 30)
133+
import time
134+
start = time.time()
131135
try:
132-
selenium_utils_get.wait.until(EC.text_to_be_present_in_element((By.ID, f"{div_id}_stdout"), "You"))
136+
long_wait.until(EC.text_to_be_present_in_element((By.ID, f"{div_id}_stdout"), "You"))
133137
except:
134138
print(selenium_utils_get.driver.find_element_by_id(f"{div_id}_stdout").text)
139+
print(time.time() - start)
135140
raise
136141
res = selenium_utils_get.driver.find_element_by_id(f"{div_id}_sql_out")
137142
assert res

0 commit comments

Comments
 (0)