Use selenium deb package in CI #461
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: | |
| push: | |
| branches: | |
| - main | |
| pull_request: | |
| jobs: | |
| lint: | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| lint-command: | |
| - bandit -r . -x ./tests | |
| - black --check --diff . | |
| - flake8 . | |
| - isort --check-only --diff . | |
| - pydocstyle . | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: actions/setup-python@v6 | |
| with: | |
| python-version: "3.x" | |
| cache: 'pip' | |
| cache-dependency-path: 'linter-requirements.txt' | |
| - run: python -m pip install -r linter-requirements.txt | |
| - run: ${{ matrix.lint-command }} | |
| dist: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: actions/setup-python@v6 | |
| with: | |
| python-version: "3.x" | |
| - run: python -m pip install --upgrade pip build wheel twine readme-renderer | |
| - run: python -m build --sdist --wheel | |
| - run: python -m twine check dist/* | |
| standardjs: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: actions/setup-node@v6 | |
| with: | |
| node-version-file: '.nvmrc' | |
| - run: npm install -g standard | |
| - run: standard | |
| docs: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: actions/setup-python@v6 | |
| with: | |
| python-version: "3.10" | |
| - run: sudo apt-get install -y gettext graphviz | |
| - run: python -m pip install -e .[docs] | |
| - run: python -m sphinx -W -b doctest -b html docs docs/_build | |
| PyTest: | |
| needs: | |
| - lint | |
| - standardjs | |
| strategy: | |
| matrix: | |
| python-version: | |
| - "3.10" | |
| - "3.11" | |
| - "3.12" | |
| - "3.13" | |
| django-version: | |
| - "4.2" | |
| - "5.1" | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: actions/setup-python@v6 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - run: python -m pip install Django~="${{ matrix.django-version }}.0" | |
| - run: python -m pip install -e .[test] | |
| - run: python -m pytest -m "not selenium" | |
| - uses: codecov/codecov-action@v5 | |
| Selenium: | |
| needs: | |
| - lint | |
| - standardjs | |
| strategy: | |
| matrix: | |
| python-version: | |
| - "3.x" | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Install Selenium | |
| run: | | |
| wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb | |
| sudo dpkg -i google-chrome-stable_current_amd64.deb || sudo apt-get -f install -y | |
| - uses: actions/setup-python@v6 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - run: python -m pip install Django | |
| - run: python -m pip install -e .[test,selenium] | |
| - run: python -m pytest -m selenium | |
| - uses: codecov/codecov-action@v5 |