File tree Expand file tree Collapse file tree 2 files changed +54
-14
lines changed
Expand file tree Collapse file tree 2 files changed +54
-14
lines changed Original file line number Diff line number Diff line change 1+ name : End-to-End Tests
2+
3+ on :
4+ push :
5+ branches : [ main ]
6+ pull_request :
7+ branches : [ main ]
8+
9+ jobs :
10+ e2e-tests :
11+ name : Run E2E Tests
12+ runs-on : ubuntu-latest
13+ steps :
14+ - uses : actions/checkout@v4
15+
16+ - name : Set up Python
17+ uses : actions/setup-python@v5
18+ with :
19+ python-version : ' 3.11'
20+
21+ - name : Set up Node.js
22+ uses : actions/setup-node@v4
23+ with :
24+ node-version : ' 22'
25+
26+ - name : Start LocalStack
27+ uses : LocalStack/setup-localstack@main
28+ with :
29+ image-tag : ' latest'
30+ use-pro : ' true'
31+ configuration : LS_LOG=trace
32+ install-awslocal : ' true'
33+ env :
34+ LOCALSTACK_AUTH_TOKEN : ${{ secrets.LOCALSTACK_AUTH_TOKEN }}
35+
36+ - name : Deploy infrastructure
37+ run : |
38+ ./bin/deploy.sh
39+
40+ - name : Install Playwright
41+ run : |
42+ cd tests/e2e
43+ pip install -r requirements.txt
44+ playwright install chromium
45+ playwright install-deps chromium
46+
47+ - name : Run E2E Tests
48+ run : |
49+ cd tests/e2e
50+ pytest -s test_quiz_flow.py
51+ env :
52+ AWS_DEFAULT_REGION : us-east-1
53+ AWS_ACCESS_KEY_ID : test
54+ AWS_SECRET_ACCESS_KEY : test
Original file line number Diff line number Diff line change @@ -124,20 +124,6 @@ def test_quiz_flow(page, app_url):
124124 found_user = True
125125 break
126126
127- # Take screenshot for debugging
128- if not found_user :
129- print ("Taking screenshot for debugging..." )
130- page .screenshot (path = "leaderboard-debug.png" )
131-
132- # Print all entries for debugging
133- print ("\n All podium entries:" )
134- for entry in podium_entries :
135- print (entry .text_content ())
136- print ("\n All list entries:" )
137- for entry in list_entries :
138- print (entry .text_content ())
139- print (f"\n Looking for username: { username } " )
140-
141127 assert found_user , "User not found in leaderboard"
142128
143129def test_quiz_creation (page , app_url ):
You can’t perform that action at this time.
0 commit comments