-
Notifications
You must be signed in to change notification settings - Fork 36
47 lines (45 loc) · 1.32 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
name: Tests
on: [push]
jobs:
test:
name: ${{ matrix.os }} (R ${{ matrix.r-version }})
runs-on: ${{ matrix.os }}
timeout-minutes: 60
strategy:
fail-fast: false
matrix:
include:
- os: ubuntu-latest
r-version: 'release'
- os: macos-latest
r-version: 'release'
steps:
- name: checkout repository
uses: actions/checkout@v2.3.4
with:
fetch-depth: 1
- name: set up R
uses: r-lib/actions/setup-r@v1
with:
r-version: ${{ matrix.r-version }}
- uses: r-lib/actions/setup-pandoc@v1
- uses: r-lib/actions/setup-tinytex@v1
- name: set up dependencies
shell: bash
env:
OS_NAME: ${{ matrix.os }}
run: $GITHUB_WORKSPACE/.github/setup.sh
- name: run tests
shell: bash
run: $GITHUB_WORKSPACE/test.sh
- name: upload coverage
if: ${{ matrix.os == 'macos-latest' && matrix.r-version == 'release' }}
shell: Rscript {0}
run: covr::codecov()
# https://github.community/t/is-it-possible-to-require-all-github-actions-tasks-to-pass-without-enumerating-them/117957/4?u=graingert
all-successful:
runs-on: ubuntu-latest
needs: [test]
steps:
- name: Note that all tests succeeded
run: echo "🎉"