-
Notifications
You must be signed in to change notification settings - Fork 20
50 lines (50 loc) · 1.71 KB
/
inox-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
48
49
50
name: Inox CI
on:
pull_request:
push:
branches:
- main
jobs:
tests:
if: github.event.pull_request.draft == false
runs-on: [self-hosted, linux]
env:
# define Java options for both official sbt and sbt-extras
JAVA_OPTS_TMP_DIR: ./tmp_java
JAVA_OPTS: -Xss64M -Xms1024M -Xmx8G -Djava.io.tmpdir=$JAVA_OPTS_TMP_DIR
JVM_OPTS: -Xss64M -Xms1024M -Xmx8G -Djava.io.tmpdir=$JAVA_OPTS_TMP_DIR
steps:
- name: Checkout
uses: actions/checkout@v4
with:
submodules: recursive
- name: Setup JDK
uses: actions/setup-java@v3
with:
distribution: temurin
java-version: 17
- name: Install and unpack sbt
run: |
wget https://github.com/sbt/sbt/releases/download/v1.10.1/sbt-1.10.1.tgz
tar xfz sbt-1.10.1.tgz
echo "PATH=./sbt/bin/:$PATH" >> "$GITHUB_ENV"
- name: Prepare temp folder
run: rm -rf $JAVA_OPTS_TMP_DIR && mkdir -p $JAVA_OPTS_TMP_DIR
- name: Install solvers
run: ./install_solvers.sh $GITHUB_WORKSPACE/.local/bin
- name: Add solvers to PATH
run: echo "$GITHUB_WORKSPACE/.local/bin" >> $GITHUB_PATH
- name: Test solvers availability
run: cvc5 --version && z3 --version && cvc4 --version
- name: Run Tests
run: sbt -Dtest-parallelism=10 -batch test
- name: Run integration tests
run: sbt -Dtest-parallelism=10 -batch it:test
- name: Clean up
run: rm -rf $JAVA_OPTS_TMP_DIR
fail_if_pull_request_is_draft:
if: github.event.pull_request.draft == true
runs-on: [self-hosted, linux]
steps:
- name: Fails in order to indicate that pull request needs to be marked as ready to review and tests workflows need to pass.
run: exit 1