88jobs :
99
1010 prepare :
11-
12- runs-on : ubuntu-latest
11+
12+ runs-on : ubuntu-latest
1313 steps :
1414 - name : Checkout code
15- uses : actions/checkout@v2
16-
15+ uses : actions/checkout@v3
16+
1717 - name : Create matrix
18- uses : fabiocaccamo/create-matrix-action@v2
18+ uses : fabiocaccamo/create-matrix-action@v3
1919 id : create_matrix
2020 with :
2121 matrix : |
22- python-version {2.7}, django-version {1.8,1.9,1.10,1.11}, database {sqlite,postgres}
23- python-version {3.6}, django-version {1.8,1.9,1.10,1.11,2.0,2.1,2.2,3.0,3.1,3.2}, database {sqlite,postgres}
24- python-version {3.7}, django-version {2.0,2.1,2.2,3.0,3.1,3.2}, database {sqlite,postgres}
25- python-version {3.8}, django-version {2.2,3.0,3.1,3.2}, database {sqlite,postgres}
26- python-version {3.9}, django-version {2.2,3.0,3.1,3.2}, database {sqlite,postgres}
27- python-version {3.10}, django-version {3.2,4.0}, database {sqlite,postgres}
28-
22+ python-version {3.8}, django-version {3.0, 3.1, 3.2, 4.0, 4.1, 4.2}, database {sqlite, postgres}
23+ python-version {3.9}, django-version {3.0, 3.1, 3.2, 4.0, 4.1, 4.2}, database {sqlite, postgres}
24+ python-version {3.10}, django-version {3.2, 4.0, 4.1, 4.2}, database {sqlite, postgres}
25+ python-version {3.11}, django-version {4.1, 4.2}, database {sqlite, postgres}
26+
2927 outputs :
3028 matrix : ${{ steps.create_matrix.outputs.matrix }}
31-
29+
30+
31+ lint :
32+
33+ runs-on : ubuntu-latest
34+ steps :
35+ - name : Checkout code
36+ uses : actions/checkout@v3
37+
38+ - name : Set up Python
39+ uses : actions/setup-python@v2
40+ with :
41+ cache : ' pip'
42+
43+ - name : Install tools needed
44+ run : |
45+ sudo apt install gettext
46+ python -m pip install --upgrade pip
47+ pip install tox
48+
49+ - name : Check migrations
50+ run : |
51+ tox -e migrations
52+
53+ - name : Check translations
54+ run : |
55+ tox -e translations
56+
57+
3258 test :
33-
34- needs : prepare
59+
60+ needs : [ prepare]
3561 runs-on : ubuntu-latest
3662 strategy :
3763 fail-fast : false
38- matrix :
64+ matrix :
3965 include : ${{fromJson(needs.prepare.outputs.matrix)}}
4066
4167 services :
@@ -52,42 +78,42 @@ jobs:
5278
5379 steps :
5480
55- - uses : actions/checkout@v2
81+ - uses : actions/checkout@v3
5682
5783 - name : Install psycopg2 prerequisites
58- run : sudo apt-get install libpq-dev
84+ run : sudo apt install libpq-dev
5985
6086 - name : Set up Python ${{ matrix.python-version }}
6187 uses : actions/setup-python@v2
6288 with :
6389 python-version : ${{ matrix.python-version }}
6490 cache : ' pip'
65-
91+
6692 - name : Upgrade pip version
6793 run : |
6894 pip install pip --upgrade
69-
95+
7096 - name : Install django
7197 run : |
72- pip install "Django ~= ${{ matrix.django-version }}"
73-
98+ pip install "Django == ${{ matrix.django-version }}.* "
99+
74100 - name : Install requirements
75101 run : |
76102 pip install -r requirements.txt
77103 pip install -r requirements-test.txt
78-
104+
79105 - name : Run tests
80- env :
106+ env :
81107 DATABASE_ENGINE : ${{ matrix.database }}
82108 run : |
83- coverage run --append --source=admin_interface setup.py test
109+ coverage run --append --source=admin_interface runtests.py
110+ coverage report --show-missing
84111 coverage xml -o ./coverage.xml
85-
112+
86113 - name : Upload coverage to Codecov
87- uses : codecov/codecov-action@v2
114+ uses : codecov/codecov-action@v3
88115 with :
89116 fail_ci_if_error : false
90117 files : ./coverage.xml
91118 flags : unittests
92119 verbose : true
93-
0 commit comments