-
Notifications
You must be signed in to change notification settings - Fork 2
133 lines (130 loc) · 3.46 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
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
132
133
name: test
on:
workflow_dispatch:
push:
branches: [ master ]
tags: [ 'v*.*' ]
pull_request:
branches: [ master ]
jobs:
test-unit:
strategy:
fail-fast: false
matrix:
os: [ ubuntu-latest, windows-latest, macos-latest ]
java: [ 8, 11, 13 ]
Rserver: [ 'R2js' , 'Renjin', 'Rserve' ]
env:
#NO_TEST_JAVA: 1
NO_TEST_MAIN: 1
NO_TEST_ISSUES: 1
NO_TEST_R: 1
NO_TEST_PYTHON: 1
NO_TEST_BASH: 1
NO_TEST_CMD: 1
NO_CALCULATORS: 1
R_SERVER: ${{ matrix.Rserver }}
runs-on: ${{ matrix.os }}
steps:
- if: matrix.Rserver == 'Rserve'
run: |
echo "R_SERVER=R://localhost" >> $GITHUB_ENV
shell: bash
- uses: actions/checkout@v2
- uses: actions/setup-java@v1
with:
java-version: ${{ matrix.java }}
java-package: jdk
- uses: r-lib/actions/setup-r@v2
with:
r-version: release
- if: matrix.os == 'macos-latest'
run: |
ln -s /Library/Frameworks/R.framework/Versions/3.6 /Library/Frameworks/R.framework/Versions/3.5
echo "/Library/Frameworks/R.framework/Resources/bin" >> $GITHUB_PATH
- uses: actions/setup-python@v2
with:
python-version: 3.9
- run: |
python -m pip install --upgrade pip
pip install py4j==0.10.8.1
pip install numpy
- if: matrix.os == 'windows-latest'
run: |
python -m venv venv3
venv3/Scripts/Activate.ps1
- run: |
WD=$PWD
cd ..
git clone https://github.com/Funz/funz-profile
git clone https://github.com/Funz/funz-core
cd funz-core
ant clean dist
cd ..
git clone https://github.com/Funz/funz-calculator
cd funz-calculator
ant clean dist
cd ..
cd $WD
shell: bash
- run: echo "R.server=$R_SERVER" > Funz.conf
shell: bash
- run: ant -noinput -buildfile build.xml test
id: anttest
continue-on-error: true
timeout-minutes: 100
- if: steps.anttest.outcome != 'success'
uses: actions/upload-artifact@v2
with:
name: artifacts-${{ matrix.os }}-${{ matrix.java }}-${{ matrix.Rserver }}-unit
path: |
*.txt
*.log
*.out
*.Rout
- if: steps.anttest.outcome != 'success'
run: exit 1
coverage:
strategy:
fail-fast: false
matrix:
os: [ ubuntu-latest ]
java: [ 11 ]
Rserver: [ 'R2js' ]
env:
#NO_TEST_JAVA: 1
NO_TEST_MAIN: 1
NO_TEST_ISSUES: 1
NO_TEST_R: 1
NO_TEST_PYTHON: 1
NO_TEST_BASH: 1
NO_TEST_CMD: 1
NO_CALCULATORS: 1
R_SERVER: ${{ matrix.Rserver }}
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v2
- uses: actions/setup-java@v1
with:
java-version: ${{ matrix.java }}
java-package: jdk
- uses: r-lib/actions/setup-r@v2
with:
r-version: release
- run: |
WD=$PWD
cd ..
git clone https://github.com/Funz/funz-profile
git clone https://github.com/Funz/funz-core
cd funz-core
ant clean dist
cd ..
git clone https://github.com/Funz/funz-calculator
cd funz-calculator
ant clean dist
cd ..
cd $WD
- run: echo "R.server=$R_SERVER" > Funz.conf
- run: ant -noinput -buildfile build.xml test
- run: ant -noinput -buildfile build.xml coverage
- uses: codecov/codecov-action@v1