Skip to content

Commit

Permalink
Use reusable workflows in pytest.yaml
Browse files Browse the repository at this point in the history
  • Loading branch information
bbrondel committed Jul 22, 2024
1 parent b311a1d commit cb58425
Showing 1 changed file with 5 additions and 14 deletions.
19 changes: 5 additions & 14 deletions .github/workflows/pytest.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,27 +9,18 @@ permissions:
contents: read

jobs:
run_pytest:
run_lint:
uses: lsst/rubin_workflows/.github/workflows/lint.yaml@main

run_pytest:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
- name: Set up Python 3.11
uses: actions/setup-python@v5
with:
python-version: "3.11"
- name: Install dependencies
- name: Editable mode install
run: |
python -m pip install uv
uv pip install flake8 pytest
uv pip install pytest
uv pip install -e .
- name: Lint with flake8
run: |
# stop the build if there are Python syntax errors or undefined names
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
# exit-zero treats all errors as warnings.
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=110 --statistics
- name: Test with pytest
run: |
pytest

0 comments on commit cb58425

Please sign in to comment.