-
Notifications
You must be signed in to change notification settings - Fork 41
52 lines (48 loc) · 1.6 KB
/
Copy pathtest.yml
File metadata and controls
52 lines (48 loc) · 1.6 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
name: test
# Run the tests when code is pushed to `main`
on:
push:
branches: [ main ]
pull_request:
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
jobs:
test:
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v6
- uses: actions/setup-java@v5
with:
distribution: 'temurin'
java-version: |
17
21
- name: Install Savant Build
run: |
curl -O https://repository.savantbuild.org/org/savantbuild/savant-core/2.2.0/savant-2.2.0.tar.gz
tar xzvf savant-2.2.0.tar.gz
savant-2.2.0/bin/sb --version
SAVANT_PATH=$(realpath -s "./savant-2.2.0/bin")
echo "${SAVANT_PATH}" >> $GITHUB_PATH
mkdir -p ~/.savant/plugins
# For now, using the JDK that comes on the GHA runner
cat << EOF > ~/.savant/plugins/org.savantbuild.plugin.java.properties
17=${JAVA_HOME_17_X64}
21=${JAVA_HOME_21_X64}
EOF
echo "~/.savant/plugins/org.savantbuild.plugin.java.properties"
cat ~/.savant/plugins/org.savantbuild.plugin.java.properties
shell: bash
- name: Run the build
run: |
export JAVA_HOME=${JAVA_HOME_21_X64}
export PATH=~/dev/savant/current/bin:${JAVA_HOME}/bin:$PATH
sb clean int --excludePerformance --excludeTimeouts
shell: bash
- name: Archive TestNG reports
if: failure()
uses: actions/upload-artifact@v6
with:
name: testng-reports
path: build/test-reports
retention-days: 1