Skip to content

Commit

Permalink
Merge branch 'main' into mb/revert-uarray-ignore
Browse files Browse the repository at this point in the history
  • Loading branch information
samuelchassot authored Dec 16, 2024
2 parents ceb48b4 + d4c2299 commit 62904d1
Show file tree
Hide file tree
Showing 3 changed files with 91 additions and 31 deletions.
25 changes: 25 additions & 0 deletions .github/workflows/bolts-CI-verification.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: Bolts CI Verification
on:
workflow_dispatch:
push:
branches:
- main
env:
# define Java options for both official sbt and sbt-extras
JAVA_OPTS: -Dsbt.io.implicit.relative.glob.conversion=allow -Xss512M -Xms1024M -Xmx12G -XX:MaxMetaspaceSize=2G -XX:+UseCodeCacheFlushing -XX:ReservedCodeCacheSize=768M
JVM_OPTS: -Dsbt.io.implicit.relative.glob.conversion=allow -Xss512M -Xms1024M -Xmx12G -XX:MaxMetaspaceSize=2G -XX:+UseCodeCacheFlushing -XX:ReservedCodeCacheSize=768M
JAVA_OPTS_TMP_DIR: /tmp/tmp_${{ github.run_id }}_${{ github.run_attempt }}
jobs:
bolts-verification:
runs-on: [self-hosted, linux]
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup
uses: ./.github/workflows/setup
with:
java-opts: ${{ env.JAVA_OPTS }}
java-version: 17
temp-dir: "/tmp/tmp_${{ github.run_id }}_${{ github.run_attempt }}"
- name: Bolts Tests with verification
run: ./run-tests.sh
44 changes: 13 additions & 31 deletions .github/workflows/bolts-CI.yml
Original file line number Diff line number Diff line change
@@ -1,46 +1,28 @@
name: Bolts CI
name: Bolts CI with admit VCs
on:
pull_request:
push:
branches:
- main

env:
# define Java options for both official sbt and sbt-extras
JAVA_OPTS: -Dsbt.io.implicit.relative.glob.conversion=allow -Xss512M -Xms1024M -Xmx12G -XX:MaxMetaspaceSize=2G -XX:+UseCodeCacheFlushing -XX:ReservedCodeCacheSize=768M
JVM_OPTS: -Dsbt.io.implicit.relative.glob.conversion=allow -Xss512M -Xms1024M -Xmx12G -XX:MaxMetaspaceSize=2G -XX:+UseCodeCacheFlushing -XX:ReservedCodeCacheSize=768M
JAVA_OPTS_TMP_DIR: /tmp/tmp_${{ github.run_id }}_${{ github.run_attempt }}
jobs:
tests:
if: github.event.pull_request.draft == false
bolts-admit-vcs:
runs-on: [self-hosted, linux]
env:
# define Java options for both official sbt and sbt-extras
JAVA_OPTS: -Dsbt.io.implicit.relative.glob.conversion=allow -Xss512M -Xms1024M -Xmx12G -XX:MaxMetaspaceSize=2G -XX:+UseCodeCacheFlushing -XX:ReservedCodeCacheSize=768M
JVM_OPTS: -Dsbt.io.implicit.relative.glob.conversion=allow -Xss512M -Xms1024M -Xmx12G -XX:MaxMetaspaceSize=2G -XX:+UseCodeCacheFlushing -XX:ReservedCodeCacheSize=768M
JAVA_OPTS_TMP_DIR: /tmp/tmp_${{ github.run_id }}_${{ github.run_attempt }}
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup
uses: ./.github/workflows/setup
with:
submodules: recursive
- name: Setup JDK
uses: actions/setup-java@v4
with:
distribution: temurin
java-opts: ${{ env.JAVA_OPTS }}
java-version: 17
- name: Setup java options
run: |
echo "JAVA_OPTS=$JAVA_OPTS -Djava.io.tmpdir=$JAVA_OPTS_TMP_DIR" >> "$GITHUB_ENV" && \
echo "JVM_OPTS=$JVM_OPTS -Djava.io.tmpdir=$JAVA_OPTS_TMP_DIR" >> "$GITHUB_ENV" && \
echo "SBT_OPTS=-Djava.io.tmpdir=$JAVA_OPTS_TMP_DIR --sbt-dir $JAVA_OPTS_TMP_DIR" >> "$GITHUB_ENV"
- name: Creating temp folder
run: rm -rf $JAVA_OPTS_TMP_DIR && mkdir -p $JAVA_OPTS_TMP_DIR && chmod 777 $JAVA_OPTS_TMP_DIR
- name: Install stainless and solvers
run: ./install_stainless_and_solvers.sh $GITHUB_WORKSPACE/.local/bin $GITHUB_WORKSPACE/.local && echo "PATH=$GITHUB_WORKSPACE/.local/bin:$PATH" >> "$GITHUB_ENV"
- name: Add stainless to PATH
run: echo "$GITHUB_WORKSPACE/.local/stainless/frontends/dotty/target/universal/stage/bin" >> $GITHUB_PATH && echo "PATH=$GITHUB_WORKSPACE/.local/stainless/frontends/dotty/target/universal/stage/bin:$PATH" >> "$GITHUB_ENV"
- name: Test stainless availability
run: stainless-dotty --version
- 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: Bolts Tests
temp-dir: "/tmp/tmp_${{ github.run_id }}_${{ github.run_attempt }}"
- name: Bolts admit VCs tests
run: ./run-tests.sh --admit-vcs
fail_if_pull_request_is_draft:
if: github.event.pull_request.draft == true
Expand Down
53 changes: 53 additions & 0 deletions .github/workflows/setup/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
name: Bolts Setup
description: Setup for Bolts CI
inputs:
java-opts:
description: 'Java options for both official sbt and sbt-extras'
required: true
default: '-Dsbt.io.implicit.relative.glob.conversion=allow -Xss512M -Xms1024M -Xmx12G -XX:MaxMetaspaceSize=2G -XX:+UseCodeCacheFlushing -XX:ReservedCodeCacheSize=768M'
temp-dir:
description: 'Temporary directory for Java options'
required: true
default: '/tmp/tmp_${{ github.run_id }}_${{ github.run_attempt }}'
java-version:
description: 'Java version to use'
required: true
default: '17'
runs:
using: 'composite'
steps:
- name: Checkout
uses: actions/checkout@v4
with:
submodules: recursive
- name: Setup JDK
uses: actions/setup-java@v4
with:
distribution: temurin
java-version: ${{ inputs.java-version }}
- name: Setup java options environment variables
run: |
echo "JAVA_OPTS=${{ inputs.java-opts }}" >> "$GITHUB_ENV" && \
echo "JVM_OPTS=${{ inputs.java-opts }}" >> "$GITHUB_ENV" && \
echo "JAVA_OPTS=$JAVA_OPTS -Djava.io.tmpdir=$JAVA_OPTS_TMP_DIR" >> "$GITHUB_ENV" && \
echo "JVM_OPTS=$JVM_OPTS -Djava.io.tmpdir=${{ inputs.temp-dir }}" >> "$GITHUB_ENV" && \
echo "SBT_OPTS=-Djava.io.tmpdir=${{ inputs.temp-dir }} --sbt-dir ${{ inputs.temp-dir }}" >> "$GITHUB_ENV"
shell: bash
- name: Creating temp folder
run: rm -rf ${{ inputs.temp-dir }} && mkdir -p ${{ inputs.temp-dir }} && chmod 777 ${{ inputs.temp-dir }}
shell: bash
- name: Install stainless and solvers
run: ./install_stainless_and_solvers.sh $GITHUB_WORKSPACE/.local/bin $GITHUB_WORKSPACE/.local && echo "PATH=$GITHUB_WORKSPACE/.local/bin:$PATH" >> "$GITHUB_ENV"
shell: bash
- name: Add stainless to PATH
run: echo "$GITHUB_WORKSPACE/.local/stainless/frontends/dotty/target/universal/stage/bin" >> $GITHUB_PATH && echo "PATH=$GITHUB_WORKSPACE/.local/stainless/frontends/dotty/target/universal/stage/bin:$PATH" >> "$GITHUB_ENV"
shell: bash
- name: Test stainless availability
run: stainless-dotty --version
shell: bash
- name: Add solvers to PATH
run: echo "$GITHUB_WORKSPACE/.local/bin" >> $GITHUB_PATH
shell: bash
- name: Test solvers availability
run: cvc5 --version && z3 --version && cvc4 --version
shell: bash

0 comments on commit 62904d1

Please sign in to comment.