-
Notifications
You must be signed in to change notification settings - Fork 68
72 lines (70 loc) · 2.04 KB
/
weekly-tests-cpu.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
name: weekly-tests-cpu
on:
# weekly tests for existing bundles in release
schedule:
- cron: "0 5 * * 0" # 5:00, every Sunday
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
jobs:
get-list:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python 3.9
uses: actions/setup-python@v2
with:
python-version: 3.9
- name: cache weekly timestamp
id: pip-cache
run: |
echo "datew=$(date '+%Y-%V')" >> $GITHUB_OUTPUT
- name: cache for pip
uses: actions/cache@v2
id: cache
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ steps.pip-cache.outputs.datew }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip wheel
python -m pip install -r requirements-dev.txt
- name: get bundle list
id: get-bundle-list
run: |
# clean up temporary files
$(pwd)/runtests.sh --clean
echo "list=$(python $(pwd)/ci/get_bundle_list.py --models_path $(pwd)/models/)" >> $GITHUB_OUTPUT
shell: bash
outputs:
list: ${{ steps.get-bundle-list.outputs.list }}
test-cpu:
needs: get-list
strategy:
matrix:
bundle: ${{ fromJson(needs.get-list.outputs.list) }}
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python 3.9
uses: actions/setup-python@v2
with:
python-version: 3.9
- name: cache weekly timestamp
id: pip-cache
run: |
echo "::set-output name=datew::$(date '+%Y-%V')"
- name: cache for pip
uses: actions/cache@v2
id: cache
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ steps.pip-cache.outputs.datew }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip wheel
- name: check
run: |
# clean up temporary files
$(pwd)/runtests.sh --clean
bash $(pwd)/ci/run_regular_tests_cpu.sh ${{ matrix.bundle }}
shell: bash