Skip to content

Commit

Permalink
Use SPARK Pro 23.0w in tests workflow
Browse files Browse the repository at this point in the history
Ref. #768, #850
  • Loading branch information
treiher committed Jan 31, 2022
1 parent c3aee5b commit 1f069e6
Show file tree
Hide file tree
Showing 3 changed files with 61 additions and 0 deletions.
31 changes: 31 additions & 0 deletions .github/actions/install_spark_pro/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: "Install SPARK Pro"

inputs:
version:
required: true
ssh_key:
required: true
server:
required: true

runs:
using: "composite"
steps:
- shell: bash
env:
VERSION: ${{ inputs.version }}
SSH_KEY: ${{ inputs.ssh_key }}
SERVER: ${{ inputs.server }}
run: |
eval $(ssh-agent -s)
echo "$SSH_KEY" | tr -d '\r' | ssh-add - &>/dev/null
mkdir -p ~/.ssh
chmod 700 ~/.ssh
ssh-keyscan $SERVER >> ~/.ssh/known_hosts
chmod 644 ~/.ssh/known_hosts
scp -q ci@$SERVER:/srv/spark-pro-$VERSION-x86_64-linux-bin.tar.gz /home/runner/work/
tar -C /home/runner/work -xzf /home/runner/work/spark-pro-$VERSION-x86_64-linux-bin.tar.gz
cd /home/runner/work/spark-pro-$VERSION-*x86_64-linux-bin && ./doinstall /home/runner/work/spark
echo "/home/runner/work/spark/bin" >> $GITHUB_PATH
export PATH=/home/runner/work/spark/bin:$PATH
gnatprove --version
27 changes: 27 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -182,6 +182,13 @@ jobs:
with:
distrib: community
install_dir: /home/runner/work/gnat
- name: Install SPARK Pro
uses: ./.github/actions/install_spark_pro
if: ${{ needs.skip_check_python.outputs.should_skip != 'true' }}
with:
version: "23.0w"
ssh_key: ${{ secrets.MEMCACHED_SSH_KEY }}
server: ${{ secrets.MEMCACHED_SERVER }}
- name: Install dependencies
if: ${{ needs.skip_check_python.outputs.should_skip != 'true' }}
run: |
Expand Down Expand Up @@ -381,6 +388,12 @@ jobs:
with:
distrib: community
install_dir: /home/runner/work/gnat
- name: Install SPARK Pro
uses: ./.github/actions/install_spark_pro
with:
version: "23.0w"
ssh_key: ${{ secrets.MEMCACHED_SSH_KEY }}
server: ${{ secrets.MEMCACHED_SERVER }}
- name: Install dependencies
run: |
echo "$HOME/.local/bin" >> $GITHUB_PATH
Expand Down Expand Up @@ -511,6 +524,13 @@ jobs:
with:
distrib: community
install_dir: /home/runner/work/gnat
- name: Install SPARK Pro
uses: ./.github/actions/install_spark_pro
if: ${{ needs.skip_check_spark.outputs.should_skip != 'true' }}
with:
version: "23.0w"
ssh_key: ${{ secrets.MEMCACHED_SSH_KEY }}
server: ${{ secrets.MEMCACHED_SERVER }}
- name: Install dependencies
if: ${{ needs.skip_check_spark.outputs.should_skip != 'true' }}
run: |
Expand Down Expand Up @@ -674,6 +694,13 @@ jobs:
with:
distrib: community
install_dir: /home/runner/work/gnat
- name: Install SPARK Pro
uses: ./.github/actions/install_spark_pro
if: ${{ needs.skip_check_apps.outputs.should_skip != 'true' }}
with:
version: "23.0w"
ssh_key: ${{ secrets.MEMCACHED_SSH_KEY }}
server: ${{ secrets.MEMCACHED_SERVER }}
- name: Install dependencies
if: ${{ needs.skip_check_apps.outputs.should_skip != 'true' }}
run: |
Expand Down
3 changes: 3 additions & 0 deletions defaults.gpr
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,9 @@ abstract project Defaults is
-- "-gnatwh", -- Activate warnings on hiding.
"-gnatwt", -- Activate warnings for tracking of deleted conditional code.

-- ISSUE: Componolit/RecordFlux#905
"-gnatwR", -- Suppress warnings on redundant constructs.

-- Style Checks
"-gnaty3", -- Specify indentation level.
"-gnatya", -- Check attribute casing.
Expand Down

0 comments on commit 1f069e6

Please sign in to comment.