-
-
Notifications
You must be signed in to change notification settings - Fork 332
131 lines (129 loc) · 3.65 KB
/
ci.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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
name: CI
on:
push:
branches:
- master
pull_request:
jobs:
test:
name: Py ${{ matrix.python }} / Django ${{ matrix.django }}
runs-on: ubuntu-latest
strategy:
matrix:
python: ['3.8', '3.9', '3.10', '3.11']
django: ['3.2', '4.2']
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python }}
uses: actions/setup-python@v1
with:
python-version: ${{ matrix.python }}
- name: Install Dependencies
run: |
python -m pip install --upgrade pip
pip install .[files,huey,celery]
pip uninstall django-spirit -y
pip install --upgrade Django==${{ matrix.django }}
pip install --upgrade coveralls
- name: Run Tests
run: |
python setup.py -q build
python ./spirit/extra/bin/spirit.py startproject project
export PYTHONWARNINGS="default"
coverage run --source=. runtests.py
- name: Submit to coveralls
env:
COVERALLS_FLAG_NAME: run-${{ matrix.python }}-${{ matrix.django }}
COVERALLS_PARALLEL: true
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
coveralls --service=github
coveralls:
name: Finish Coveralls
needs: test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python 3.11
uses: actions/setup-python@v1
with:
python-version: 3.11
- name: Finished
run: |
python -m pip install --upgrade pip
pip install --upgrade coveralls
coveralls --finish
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
test_js:
name: JS
runs-on: ubuntu-latest
strategy:
matrix:
node: [12.x]
steps:
- uses: actions/checkout@v2
- name: Set Up NodeJS ${{ matrix.node }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node }}
- name: Install Dependencies
run: |
npm install -g yarn
npm install -g jasmine@3.6.1
yarn
- name: Run Tests
run: |
make testjs
test_no_deps:
name: No-deps / Py ${{ matrix.python }} / Django ${{ matrix.django }}
runs-on: ubuntu-latest
strategy:
matrix:
python: ['3.11']
django: ['4.2']
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python }}
uses: actions/setup-python@v1
with:
python-version: ${{ matrix.python }}
- name: Install Dependencies
run: |
python -m pip install --upgrade pip
pip install .
pip uninstall django-spirit -y
pip install --upgrade Django==${{ matrix.django }}
- name: Run Tests
run: |
python ./spirit/extra/bin/spirit.py startproject project
export PYTHONWARNINGS="default"
export ST_UPLOAD_FILE_ENABLED=0
export ST_INSTALL_HUEY=0
make test
test_huey:
name: Huey / Py ${{ matrix.python }} / Django ${{ matrix.django }}
runs-on: ubuntu-latest
strategy:
matrix:
python: ['3.11']
django: ['4.2']
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python }}
uses: actions/setup-python@v1
with:
python-version: ${{ matrix.python }}
- name: Install Dependencies
run: |
python -m pip install --upgrade pip
pip install .[huey]
pip uninstall django-spirit -y
pip install --upgrade Django==${{ matrix.django }}
- name: Run Tests
run: |
python ./spirit/extra/bin/spirit.py startproject project
export PYTHONWARNINGS="default"
export ST_UPLOAD_FILE_ENABLED=0
export ST_TASK_MANAGER="huey"
make test