Skip to content

Commit

Permalink
GHA: Test composite actions
Browse files Browse the repository at this point in the history
  • Loading branch information
dweindl committed Nov 15, 2023
1 parent eccdc1f commit fef657e
Show file tree
Hide file tree
Showing 9 changed files with 41 additions and 44 deletions.
15 changes: 15 additions & 0 deletions .github/actions/install-apt-dependencies/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
name: Install apt dependencies
description: Install apt dependencies for the AMICI Python package
runs:
using: "composite"
steps:
- run: |
sudo apt-get update \
&& sudo apt-get install -y \
libatlas-base-dev \
libboost-chrono-dev \
libboost-math-dev \
libboost-serialization-dev \
libhdf5-serial-dev \
swig
shell: bash
7 changes: 2 additions & 5 deletions .github/workflows/test_benchmark_collection_models.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,8 @@ jobs:
with:
fetch-depth: 20

# install dependencies
- name: apt
run: |
sudo apt-get update \
&& sudo apt-get install -y swig libatlas-base-dev
- name: Install apt dependencies
uses: ./.github/actions/install-apt-dependencies

- run: echo "${HOME}/.local/bin/" >> $GITHUB_PATH

Expand Down
10 changes: 4 additions & 6 deletions .github/workflows/test_install.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,17 +22,15 @@ jobs:

- run: echo "AMICI_DIR=$(pwd)" >> $GITHUB_ENV

# install amici dependencies
- name: Install apt dependencies
uses: ./.github/actions/install-apt-dependencies

- name: apt
run: |
sudo apt-get update \
&& sudo apt-get install -y \
cmake \
g++ \
libatlas-base-dev \
libboost-serialization-dev \
libhdf5-serial-dev \
swig
g++
- name: Build suitesparse
run: |
Expand Down
8 changes: 3 additions & 5 deletions .github/workflows/test_performance.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,9 @@ jobs:
with:
fetch-depth: 20

# install dependencies
- name: apt
run: |
sudo apt-get update \
&& sudo apt-get install -y swig libatlas-base-dev
- name: Install apt dependencies
uses: ./.github/actions/install-apt-dependencies

- run: pip3 install petab shyaml build

- run: echo "${HOME}/.local/bin/" >> $GITHUB_PATH
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/test_petab_test_suite.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,14 +34,14 @@ jobs:
with:
fetch-depth: 20

- name: Install apt dependencies
uses: ./.github/actions/install-apt-dependencies

# install dependencies
- name: apt
run: |
sudo apt-get update \
&& sudo apt-get install -y \
swig \
libatlas-base-dev \
python3-venv
&& sudo apt-get install -y python3-venv
- name: Build BNGL
run: |
Expand Down
8 changes: 3 additions & 5 deletions .github/workflows/test_python_cplusplus.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,19 +53,17 @@ jobs:
https://sonarcloud.io/static/cpp/build-wrapper-linux-x86.zip \
&& unzip -o $HOME/.sonar/build-wrapper-linux-x86.zip -d $HOME/.sonar/ \
- name: Install apt dependencies
uses: ./.github/actions/install-apt-dependencies

# install amici dependencies
- name: apt
run: |
sudo apt-get update \
&& sudo apt-get install -y \
cmake \
g++ \
libatlas-base-dev \
libboost-serialization-dev \
libboost-chrono-dev \
libhdf5-serial-dev \
python3-venv \
swig \
lcov \
libboost-math-dev
Expand Down
11 changes: 2 additions & 9 deletions .github/workflows/test_python_ver_matrix.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,15 +41,8 @@ jobs:
with:
fetch-depth: 20

# install dependencies
- name: apt
run: |
sudo apt-get update \
&& sudo apt-get install -y \
swig \
libatlas-base-dev \
libhdf5-serial-dev \
libboost-math-dev
- name: Install apt dependencies
uses: ./.github/actions/install-apt-dependencies

# install AMICI
- name: Build BNGL
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/test_sbml_semantic_test_suite.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,10 @@ jobs:
- uses: actions/checkout@v3
with:
fetch-depth: 1
- name: apt
run: |
sudo apt-get update \
&& sudo apt-get install -y swig4.0 libatlas-base-dev

- name: Install apt dependencies
uses: ./.github/actions/install-apt-dependencies

- run: AMICI_PARALLEL_COMPILE=2 ./scripts/installAmiciSource.sh
- run: AMICI_PARALLEL_COMPILE=2 ./scripts/run-SBMLTestsuite.sh ${{ matrix.cases }}

Expand Down
10 changes: 4 additions & 6 deletions .github/workflows/test_valgrind.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,20 +34,18 @@ jobs:
- uses: actions/checkout@v3
- run: git fetch --prune --unshallow

- name: Install apt dependencies
uses: ./.github/actions/install-apt-dependencies

# install amici dependencies
- name: apt
run: |
sudo apt-get update \
&& sudo apt-get install -y \
cmake \
g++ \
libatlas-base-dev \
libboost-serialization-dev \
libhdf5-serial-dev \
python3-venv \
swig \
valgrind \
libboost-math-dev
valgrind
- name: Build AMICI
run: |
Expand Down

0 comments on commit fef657e

Please sign in to comment.