Skip to content

do not remove node_modules #31

do not remove node_modules

do not remove node_modules #31

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