From d239b7b3b3aaefa5ff7753dd0c9cf5baffad3538 Mon Sep 17 00:00:00 2001 From: Luis Manuel Diaz Angulo Date: Fri, 27 Dec 2024 08:58:13 +0100 Subject: [PATCH] Reorder Python wrapper requirements installation --- .github/workflows/ubuntu.yml | 17 +++++++-------- .github/workflows/windows-intelLLVM.yml | 28 +++++++++++++------------ 2 files changed, 23 insertions(+), 22 deletions(-) diff --git a/.github/workflows/ubuntu.yml b/.github/workflows/ubuntu.yml index 7a1f1ea3..752455fe 100644 --- a/.github/workflows/ubuntu.yml +++ b/.github/workflows/ubuntu.yml @@ -48,13 +48,17 @@ jobs: with: submodules: 'recursive' + + - name: Install python wrapper requirements + run: python -m pip install -r requirements.txt + - name: Setup MPI if: matrix.mpi=='Yes' && matrix.compiler.name=='intel' uses: mpi4py/setup-mpi@v1 with: mpi: 'intelmpi' - - name: Install required packages + - name: Install gcc required packages if: matrix.compiler.name=='gcc' run: | sudo apt update @@ -76,15 +80,10 @@ jobs: -DSEMBA_FDTD_ENABLE_MTLN=${{matrix.mtln}} cmake --build build -j - - name: Run fdtd unit tests - run: | - build/bin/fdtd_tests - - - name: Install python wrapper requirements - run: | - python -m pip install -r requirements.txt + - name: Run unit tests + run: build/bin/fdtd_tests - - name: Run all wrapper tests + - name: Run python tests env: SEMBA_FDTD_ENABLE_MTLN: ${{ matrix.mtln }} SEMBA_FDTD_ENABLE_HDF: ${{ matrix.hdf }} diff --git a/.github/workflows/windows-intelLLVM.yml b/.github/workflows/windows-intelLLVM.yml index 32be3a69..9d1f5339 100644 --- a/.github/workflows/windows-intelLLVM.yml +++ b/.github/workflows/windows-intelLLVM.yml @@ -16,7 +16,8 @@ jobs: builds-and-tests: runs-on: windows-latest strategy: - matrix: + matrix: + compiler: [ {name: 'intel', version: '2024.0'} ] build-type: ["Debug", "Release"] mpi: ["No"] mtln: ["Yes"] @@ -28,6 +29,8 @@ jobs: mtln: "No" hdf: "Yes" + fail-fast: false + name: ${{matrix.build-type}}-mpi(${{matrix.mpi}})-mtln(${{matrix.mtln}})-hdf(${{matrix.hdf}}) steps: @@ -35,6 +38,10 @@ jobs: - uses: actions/checkout@v4 with: submodules: 'recursive' + + - name: Install python wrapper requirements + run: | + python -m pip install -r requirements.txt - name: Setup MPI uses: mpi4py/setup-mpi@v1 @@ -45,8 +52,8 @@ jobs: uses: fortran-lang/setup-fortran@v1 id: setup-fortran with: - compiler: intel - version: '2024.0' + compiler: ${{ matrix.compiler.name }} + version: ${{ matrix.compiler.version }} - name: Setup ninja uses: seanmiddleditch/gha-setup-ninja@master @@ -60,15 +67,10 @@ jobs: -DSEMBA_FDTD_ENABLE_HDF=${{matrix.hdf}} \ -DSEMBA_FDTD_ENABLE_MTLN=${{matrix.mtln}} cmake --build build -j - - - name: Install python wrapper requirements - run: | - python -m pip install -r requirements.txt - - name: Run all wrapper tests (except codemodel) - if: matrix.mtln=='Yes' + - name: Run python tests (except codemodel) + env: + SEMBA_FDTD_ENABLE_MTLN: ${{ matrix.mtln }} + SEMBA_FDTD_ENABLE_HDF: ${{ matrix.hdf }} run: python -m pytest -m 'not codemodel' test/ - - - name: Run non-mtln wrapper tests - if: matrix.mtln=='No' - run: python -m pytest -m 'not mtln' test/ \ No newline at end of file + \ No newline at end of file