-
Notifications
You must be signed in to change notification settings - Fork 6
49 lines (47 loc) · 1.4 KB
/
test.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
# django-opensearch
# .github/workflows/test.yml
name: "test"
on:
workflow_dispatch:
workflow_call:
env:
NAME: "opensearch"
jobs:
test:
name: "${{ matrix.python-version }}"
runs-on: "ubuntu-latest"
strategy:
matrix:
python-version: ["3.7", "3.8", "3.9", "3.10"]
steps:
- name: "Git clone"
id: "git-clone"
uses: "actions/checkout@v2"
- name: "Set up Python ${{ matrix.python-version }}"
id: "set-up-python"
uses: "actions/setup-python@v2"
with:
python-version: "${{ matrix.python-version }}"
- name: "Pip cache"
id: "pip-cache"
uses: "actions/cache@v2"
with:
path: "~/.cache/pip"
key: "${{ runner.os }}-pip-${{ matrix.python-version }}-${{ hashFiles('setup.cfg') }}"
restore-keys: |
"${{ runner.os }}-pip-${{ matrix.python-version }}-"
"${{ runner.os }}-pip-"
- name: "Temporarily save coverage statistics"
id: "temporarily-save-coverage-statistics"
uses: "actions/cache@v2"
with:
path: ".coverage"
key: ".coverage-${{ github.run_id }}-${{ github.run_number }}"
- name: "Install requirements"
id: "install-requirements"
run: "make install"
- name: "Run tests"
id: "run-tests"
env:
PLATFORM: "${{ matrix.platform }}"
run: "make tox"