Merge for release v1.0.1 #122
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: | |
push: | |
branches: [ "CI_workflows" ] | |
pull_request: | |
branches: [ "main" , "release" ] | |
permissions: | |
contents: write | |
jobs: | |
testing: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
python-version: ["3.10", "3.11", "3.12"] | |
steps: | |
- name: Checkout Repository | |
uses: actions/checkout@v2 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v4 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Set environment variables | |
run: | | |
echo "HOME=$GITHUB_WORKSPACE" >> $GITHUB_ENV | |
echo "HOME_OASIS=$GITHUB_WORKSPACE/oasis3-mct" >> $GITHUB_ENV | |
- name: Install MPI, Netcdf for C and Fortran | |
run: | | |
sudo apt -y install openmpi-bin libopenmpi-dev gcc g++ gfortran libnetcdf-dev libnetcdff-dev | |
- name: Install eophis | |
run: | | |
cd $HOME | |
pip install .[dev] | |
- name: Checkout OASIS | |
run: | | |
git clone https://gitlab.com/cerfacs/oasis3-mct.git $HOME_OASIS | |
- name: Install OASIS | |
run: | | |
cd $HOME_OASIS/util/make_dir | |
export ARCH=x86_64-linux-gnu | |
echo "include $HOME/.github/workflows/make.gnu" > make.inc | |
make -f TopMakefileOasis3 pyoasis | |
- name: Run Eophis unit tests | |
run: | | |
source $HOME_OASIS/BLD/python/init.sh | |
cd $HOME/tests/unit_tests | |
pytest | |
- name: Run operating tests | |
run: | | |
source $HOME_OASIS/BLD/python/init.sh | |
cd $HOME/tests/ | |
./run_all_tests.sh |