11name : CI
2-
32on :
4- # Triggers the workflow on push or pull request events but only for the master branch
53 push :
6- branches : [ master ]
4+ branches :
5+ - master
76 pull_request :
8- branches : [ master ]
9-
107jobs :
11- build :
12-
8+ tox :
139 runs-on : ubuntu-latest
1410 strategy :
11+ fail-fast : false
1512 matrix :
16- python-version : ["3.8", "3.9", "3.10", "3.11"]
17- scrapy-version : ["2.11", "2.10"]
18-
13+ include :
14+ - python-version : " 3.13"
15+ tox : " pre-commit"
16+ - python-version : " 3.9"
17+ tox : " mypy"
18+ - python-version : " 3.13"
19+ tox : " pylint"
20+ - python-version : " 3.9"
21+ tox : " min"
22+ - python-version : " 3.10"
23+ - python-version : " 3.11"
24+ - python-version : " 3.12"
25+ - python-version : " 3.13"
26+ - python-version : " 3.13" # Keep in sync with .readthedocs.yml
27+ tox : " docs"
28+ - python-version : " 3.13"
29+ tox : " twinecheck"
1930 steps :
20- - uses : actions/checkout@v2
31+ - uses : actions/checkout@v4
2132 - name : Set up Python ${{ matrix.python-version }}
22- uses : actions/setup-python@v2
33+ uses : actions/setup-python@v5
2334 with :
2435 python-version : ${{ matrix.python-version }}
25- scrapy-version : ${{ matrix.scrapy-version }}
26- - name : Install dependencies
36+ - name : Run tox
2737 run : |
28- python -m pip install --upgrade pip
29- pip install scrapy==${{ matrix.scrapy-version}}
30- pip install -r requirements-dev.txt
31- # - name: Lint with flake8
32- # run: |
33- # # stop the build if there are Python syntax errors or undefined names
34- # flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
35- # # exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
36- # flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
37- - name : Test with pytest
38- run : |
39- pytest
38+ pip install -U tox
39+ tox -e ${{ matrix.tox || 'py' }}
0 commit comments