-
Notifications
You must be signed in to change notification settings - Fork 0
71 lines (58 loc) · 1.76 KB
/
ui_firefox_pytest.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
name: UI Automation Test for Firefox
on:
pull_request:
branches:
- main
jobs:
build_and_test:
runs-on: ubuntu-latest
steps:
- name: Checkout resume repository
uses: actions/checkout@v3
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: '18'
- name: Install dependencies and build
run: |
yarn install
yarn build
- name: Start the application
run: |
yarn start &
env:
PORT: 3000
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.12'
- name: Set up Firefox and GeckoDriver
uses: browser-actions/setup-firefox@latest
- name: Clone the test repository
run: |
git clone https://github.com/serhatozdursun/serhatozdursun-ui-tests.git
env:
GITHUB_TOKEN: ${{ secrets.UI_TEST_TOKEN }}
- name: Install Python dependencies
working-directory: serhatozdursun-ui-tests
run: |
pip install -r requirements.txt
- name: Run tests
working-directory: serhatozdursun-ui-tests
id: run_tests
run: |
pytest --browser firefox --base_url http://localhost:3000 --html=reports/html/report.html --junitxml=reports/report.xml
- name: Upload HTML report
if: always()
uses: actions/upload-artifact@v4
with:
name: html-report
path: serhatozdursun-ui-tests/reports/html
continue-on-error: true
- name: Upload XML report
if: always()
uses: actions/upload-artifact@v4
with:
name: xml-report
path: serhatozdursun-ui-tests/reports/report.xml
continue-on-error: true