forked from RustPython/RustPython
-
Notifications
You must be signed in to change notification settings - Fork 0
88 lines (84 loc) · 2.74 KB
/
cron-ci.yaml
File metadata and controls
88 lines (84 loc) · 2.74 KB
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
on:
schedule:
- cron: '0 0 * * 6'
jobs:
redox:
name: Check compilation on Redox
runs-on: ubuntu-latest
container:
image: redoxos/redoxer:latest
steps:
- uses: actions/checkout@master
- name: prepare repository for redoxer compilation
run: bash scripts/redox/uncomment-cargo.sh
- name: compile for redox
run: redoxer build --verbose
codecov:
name: Collect code coverage data
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- uses: actions-rs/toolchain@v1
with:
toolchain: nightly
override: true
- uses: actions-rs/cargo@v1
with:
command: build
args: --verbose
env:
CARGO_INCREMENTAL: '0'
RUSTFLAGS: '-Zprofile -Ccodegen-units=1 -Cinline-threshold=0 -Clink-dead-code -Coverflow-checks=off -Zno-landing-pads'
- uses: actions/setup-python@v1
with:
python-version: 3.8
- name: Install pipenv
run: |
python -V
python -m pip install --upgrade pip
python -m pip install pipenv
- run: pipenv install
working-directory: ./tests
- name: run snippets
run: pipenv run pytest -v
working-directory: ./tests
env:
RUSTPYTHON_DEBUG: 'true'
- name: run cpython tests
run: cargo run -- -m test -v
env:
RUSTPYTHONPATH: ${{ github.workspace }}/Lib
- uses: actions-rs/grcov@v0.1
id: coverage
- name: upload to Codecov
uses: codecov/codecov-action@v1
with:
file: ${{ steps.coverage.outputs.report }}
testdata:
name: Collect regression test data
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- name: build rustpython
uses: actions-rs/cargo@v1
with:
command: build
args: --release --verbose --all
- name: collect tests data
run: cargo run --release tests/jsontests.py
env:
RUSTPYTHONPATH: ${{ github.workspace }}/Lib
- name: upload tests data to the website
env:
SSHKEY: ${{ secrets.ACTIONS_TESTS_DATA_DEPLOY_KEY }}
GITHUB_ACTOR: ${{ github.actor }}
run: |
echo "$SSHKEY" >~/github_key
chmod 600 ~/github_key
export GIT_SSH_COMMAND="ssh -i ~/github_key"
git clone git@github.com:RustPython/rustpython.github.io.git website
cd website
cp ../tests/cpython_tests_results.json ./_data/regrtests_results.json
git add ./_data/regrtests_results.json
git -c user.name="Github Actions" -c user.email="actions@github.com" commit -m "Update regression test results" --author="$GITHUB_ACTOR"
git push