Skip to content

chore: version bump #172

chore: version bump

chore: version bump #172

Workflow file for this run

name: Software test, formatting & publishing
on:
push:
paths:
- 'src/lavague/**.py'
- '.github/setup-driver.sh'
- 'examples/configurations/**'
- 'examples/instructions/**'
jobs:
lint:
name: Run Ruff Linter
runs-on: ubuntu-latest
steps:
- name: Check out code
uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.8'
- name: Install Ruff
run: pip install ruff
- name: Run Ruff on src/lavague
run: ruff format src/lavague/
- name: Run Ruff on examples
run: ruff format examples/
test:
name: Run Installation and Tests
runs-on: ubuntu-latest
needs: lint
steps:
- name: Check out code
uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.8'
- name: Install necessary dependencies
run: |
pip install -e '.[playwright]'
playwright install chromium
- name: Run selenium test
run: lavague -c examples/test-configurations/test_selenium.py -i examples/instructions/hackernews.yaml test
- name: Run playwright test
run: lavague -c examples/test-configurations/test_playwright.py -i examples/instructions/hackernews.yaml test
- name: Execute Generated Python Scripts
run: python hackernews_test_selenium_gen.py && python hackernews_test_playwright_gen.py
- name: Check Execution Status
if: ${{ failure() }}
run: echo "Script execution failed" && exit 1
publish:
name: Push on PyPI
runs-on: ubuntu-latest
needs: test
if: startsWith(github.ref, 'refs/tags/v')
steps:
- name: Check out code
uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.8'
- name: Install twine & build
run: >-
python3 -m
pip install
twine build
--user
- name: Build the wheel and the source tarball
run: python3 -m build
- name: Publish to github
env:
TWINE_USERNAME: __token__
TWINE_PASSWORD: ${{ secrets.TWINE_PASSWORD }}
run: twine upload dist/*