-
Notifications
You must be signed in to change notification settings - Fork 36
51 lines (44 loc) · 1.66 KB
/
tests.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
name: Run test suite
on: [push, pull_request]
jobs:
tests:
name: python ${{ matrix.python-version }}
runs-on: ubuntu-20.04
strategy:
matrix:
python-version: [3.6, 3.7, 3.8, 3.9, "3.10", "3.11", "3.12", "pypy3.9"]
pytest-extra-options: ["--strict-config -W \"ignore:pkg_resources is deprecated\""]
include:
- python-version: "pypy2.7"
pytest-extra-options: ""
- python-version: "3.13.0-beta.2"
pytest-extra-options: "--strict-config -W \"ignore:pkg_resources is deprecated\" -W ignore::DeprecationWarning"
fail-fast: false
steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install genshi
run: |
pip install -e .
- name: Install testing requirements
run: |
pip install setuptools pytest
- name: Run test suite
run: |
pytest -Werror --strict-markers --verbosity=1 --color=yes ${{ matrix.pytest-extra-options }} genshi
# Above flags are:
# -Werror
# treat warnings as errors
# --strict-config
# error out if the configuration file is not parseable
# --strict-markers
# error out if a marker is used but not defined in the
# configuration file
# --verbosity=1
# turn the verbosity up so pytest prints the names of the tests
# it's currently working on
# --color=yes
# force coloured output in the terminal