From 01fd60c9c827cb0c18584899cb926d65db54a19d Mon Sep 17 00:00:00 2001 From: Luis Manuel Diaz Angulo Date: Thu, 26 Dec 2024 11:04:10 +0100 Subject: [PATCH 1/7] Trying new action --- .github/workflows/ubuntu.yml | 95 ++++++++++++++++++++++++++++++++++++ 1 file changed, 95 insertions(+) create mode 100644 .github/workflows/ubuntu.yml diff --git a/.github/workflows/ubuntu.yml b/.github/workflows/ubuntu.yml new file mode 100644 index 00000000..732a2a46 --- /dev/null +++ b/.github/workflows/ubuntu.yml @@ -0,0 +1,95 @@ +name: ubuntu-gnu + +on: + pull_request: + branches: + - main + - dev + +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true + +jobs: + + builds-and-test: + runs-on: ubuntu-latest + strategy: + matrix: + compiler: [ + {name: 'intel', version: '2024.2'}, + {name: 'gcc', version: 11} + ] + build-type: ["Debug", "Release"] + mpi: ["Yes", "No"] + mtln: ["Yes"] + hdf: ["Yes"] + + include: + - compiler: {name: 'intel-classic', version: '2021.10'} + build-type: "Release" + mpi: "No" + mtln: "No" + hdf: "Yes" + - compiler: {name: 'nvidia-hpc', version: '24.5'} + build-type: "Release" + mpi: "No" + mtln: "No" + hdf: "No" + + + fail-fast: false + + name: ${{matrix.compiler.name}}-${{matrix.build-type}}-mpi(${{matrix.mpi}})-mtln(${{matrix.mtln}})-hdf(${{matrix.hdf}}) + + steps: + - name: Checkout + uses: actions/checkout@v4 + with: + submodules: 'recursive' + + - name: Setup MPI + if: matrix.mpi=='Yes' && matrix.compiler.name=='intel' + uses: mpi4py/setup-mpi@v1 + with: + mpi: 'intelmpi' + + - name: Install required packages + if: matrix.compiler.name=='gnu' + run: | + sudo apt update + sudo apt install libhdf5-dev libopenmpi-dev + + - name: Setup fortran compiler + uses: fortran-lang/setup-fortran@v1 + id: setup-fortran + with: + compiler: ${{matrix.compiler.name}} + version: ${{matrix.compiler.version}} + + - name: Build application + run: | + cmake -S . -B build \ + -DCMAKE_BUILD_TYPE=${{matrix.build-type}} \ + -DSEMBA_FDTD_ENABLE_MPI=${{matrix.mpi}} \ + -DSEMBA_FDTD_ENABLE_HDF=${{matrix.hdf}} \ + -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 all wrapper tests + if: matrix.mtln=='Yes' + run: python -m pytest test/ + + - name: Run non-mtln wrapper tests + if: matrix.mtln=='No' + run: python -m pytest -m 'not mtln' test/ + + From 257679cfc481e636fc1d9a0203d27b30da144626 Mon Sep 17 00:00:00 2001 From: Luis Manuel Diaz Angulo Date: Thu, 26 Dec 2024 11:16:51 +0100 Subject: [PATCH 2/7] Fixing coalesced action --- .github/workflows/ubuntu.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ubuntu.yml b/.github/workflows/ubuntu.yml index 732a2a46..6264c284 100644 --- a/.github/workflows/ubuntu.yml +++ b/.github/workflows/ubuntu.yml @@ -1,4 +1,4 @@ -name: ubuntu-gnu +name: ubuntu on: pull_request: @@ -55,7 +55,7 @@ jobs: mpi: 'intelmpi' - name: Install required packages - if: matrix.compiler.name=='gnu' + if: matrix.compiler.name=='gcc' run: | sudo apt update sudo apt install libhdf5-dev libopenmpi-dev From 086a3befbdbd15b91b0b5ed4f766591677457734 Mon Sep 17 00:00:00 2001 From: Luis Manuel Diaz Angulo Date: Thu, 26 Dec 2024 22:03:22 +0100 Subject: [PATCH 3/7] Fixing ubuntu.yml action --- .github/workflows/ubuntu-gnu.yml | 68 ------------------------ .github/workflows/ubuntu-intel.yml | 69 ------------------------- .github/workflows/ubuntu-intelLLVM.yml | 68 ------------------------ .github/workflows/ubuntu-nvidia.yml | 66 ----------------------- .github/workflows/ubuntu.yml | 12 ++--- .github/workflows/windows-intelLLVM.yml | 2 +- pytest.ini | 2 +- test/pyWrapper/test_full_system.py | 7 ++- test/pyWrapper/test_mtln_standalone.py | 7 +++ test/pyWrapper/utils.py | 11 ++++ 10 files changed, 30 insertions(+), 282 deletions(-) delete mode 100644 .github/workflows/ubuntu-gnu.yml delete mode 100644 .github/workflows/ubuntu-intel.yml delete mode 100644 .github/workflows/ubuntu-intelLLVM.yml delete mode 100644 .github/workflows/ubuntu-nvidia.yml diff --git a/.github/workflows/ubuntu-gnu.yml b/.github/workflows/ubuntu-gnu.yml deleted file mode 100644 index 633abaf5..00000000 --- a/.github/workflows/ubuntu-gnu.yml +++ /dev/null @@ -1,68 +0,0 @@ -name: ubuntu-gnu - -on: - pull_request: - branches: - - main - - dev - -concurrency: - group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} - cancel-in-progress: true - -jobs: - - builds-and-test: - runs-on: ubuntu-latest - strategy: - matrix: - build-type: ["Debug", "Release"] - mpi: ["No", "Yes"] - mtln: ["Yes"] - hdf: ["Yes"] - - include: - - build-type: "Release" - mpi: "Yes" - mtln: "No" - hdf: "Yes" - - name: ${{matrix.build-type}}- mpi ${{matrix.mpi}} - mtln ${{matrix.mtln}} - hdf ${{matrix.hdf}} - - steps: - - name: Checkout - uses: actions/checkout@v4 - with: - submodules: 'recursive' - - - name: Install required packages - run: | - sudo apt update - sudo apt install libhdf5-dev libopenmpi-dev - - - name: Build application - run: | - cmake -S . -B build \ - -DCMAKE_BUILD_TYPE=${{matrix.build-type}} \ - -DSEMBA_FDTD_ENABLE_MPI=${{matrix.mpi}} \ - -DSEMBA_FDTD_ENABLE_HDF=${{matrix.hdf}} \ - -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 all wrapper tests - if: matrix.mtln=='Yes' - run: python -m pytest test/ - - - name: Run non-mtln wrapper tests - if: matrix.mtln=='No' - run: python -m pytest -m 'not mtln' test/ - - diff --git a/.github/workflows/ubuntu-intel.yml b/.github/workflows/ubuntu-intel.yml deleted file mode 100644 index 047aa3f2..00000000 --- a/.github/workflows/ubuntu-intel.yml +++ /dev/null @@ -1,69 +0,0 @@ -name: ubuntu-intel - -on: - pull_request: - branches: - - main - - dev - -concurrency: - group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} - cancel-in-progress: true - -jobs: - - builds-and-tests: - runs-on: ubuntu-latest - strategy: - matrix: - build-type: ["Debug", "Release"] - mpi: ["No"] - mtln: ["No"] - hdf: ["Yes"] - - - name: ${{matrix.build-type}}- mpi ${{matrix.mpi}} - mtln ${{matrix.mtln}} - hdf ${{matrix.hdf}} - - steps: - - - uses: actions/checkout@v4 - with: - submodules: 'recursive' - - - name: Setup MPI - uses: mpi4py/setup-mpi@v1 - with: - mpi: 'intelmpi' - - - name: Setup intel fortran - uses: fortran-lang/setup-fortran@v1 - id: setup-fortran - with: - compiler: intel-classic - version: '2021.10' - - - name: CMake build - run: | - cmake -S . -B build \ - -DCMAKE_BUILD_TYPE=${{matrix.build-type}} \ - -DSEMBA_FDTD_ENABLE_MPI=${{matrix.mpi}} \ - -DSEMBA_FDTD_ENABLE_HDF=${{matrix.hdf}} \ - -DSEMBA_FDTD_ENABLE_MTLN=${{matrix.mtln}} - cmake --build build -j - - - name: Run fdtd unit tests - timeout-minutes: 60 - run: | - build/bin/fdtd_tests - - - name: Install python wrapper requirements - run: | - python -m pip install -r requirements.txt - - - name: Run all wrapper tests - if: matrix.mtln=='Yes' - run: python -m pytest 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 diff --git a/.github/workflows/ubuntu-intelLLVM.yml b/.github/workflows/ubuntu-intelLLVM.yml deleted file mode 100644 index 8be863dd..00000000 --- a/.github/workflows/ubuntu-intelLLVM.yml +++ /dev/null @@ -1,68 +0,0 @@ -name: ubuntu-intelLLVM - -on: - - pull_request: - branches: - - main - - dev - -concurrency: - group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} - cancel-in-progress: true - -jobs: - - builds-and-tests: - runs-on: ubuntu-latest - strategy: - matrix: - build-type: ["Debug", "Release"] - mpi: ["No", "Yes"] - mtln: ["Yes"] - hdf: ["Yes"] - - name: ${{matrix.build-type}}- mpi ${{matrix.mpi}} - mtln ${{matrix.mtln}} - hdf ${{matrix.hdf}} - - steps: - - - uses: actions/checkout@v4 - with: - submodules: 'recursive' - - - name: Setup MPI - uses: mpi4py/setup-mpi@v1 - with: - mpi: 'intelmpi' - - - name: Setup intel fortran - uses: fortran-lang/setup-fortran@v1 - id: setup-fortran - with: - compiler: intel - version: '2024.2' - - - name: CMake build - run: | - cmake -S . -B build \ - -DCMAKE_BUILD_TYPE=${{matrix.build-type}} \ - -DSEMBA_FDTD_ENABLE_MPI=${{matrix.mpi}} \ - -DSEMBA_FDTD_ENABLE_HDF=${{matrix.hdf}} \ - -DSEMBA_FDTD_ENABLE_MTLN=${{matrix.mtln}} - cmake --build build -j - - - name: Run fdtd unit tests - timeout-minutes: 60 - run: | - build/bin/fdtd_tests - - - name: Install python wrapper requirements - run: | - python -m pip install -r requirements.txt - - - name: Run wrapper tests - timeout-minutes: 60 - run: | - python -m pytest test - - diff --git a/.github/workflows/ubuntu-nvidia.yml b/.github/workflows/ubuntu-nvidia.yml deleted file mode 100644 index f85802f1..00000000 --- a/.github/workflows/ubuntu-nvidia.yml +++ /dev/null @@ -1,66 +0,0 @@ -name: ubuntu-nvhpc - -on: - pull_request: - branches: - - main - - dev - -concurrency: - group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} - cancel-in-progress: true - -jobs: - builds-and-test: - runs-on: ubuntu-latest - - strategy: - matrix: - build-type: ["Debug", "Release"] - mpi: ["No"] - mtln: ["No"] - hdf: ["No"] - - name: ${{matrix.build-type}}- mpi ${{matrix.mpi}} - mtln ${{matrix.mtln}} - hdf ${{matrix.hdf}} - - timeout-minutes: 30 - steps: - - name: Checkout - uses: actions/checkout@v4 - with: - submodules: 'recursive' - - - uses: fortran-lang/setup-fortran@v1 - id: setup-fortran - with: - compiler: nvidia-hpc - version: '24.5' - - - name: Install required packages - run: | - sudo apt update - sudo apt install libhdf5-dev libopenmpi-dev - - - name: Build application - run: | - cmake -S . -B build \ - -DCMAKE_BUILD_TYPE=${{matrix.build-type}} \ - -DSEMBA_FDTD_ENABLE_MPI=${{matrix.mpi}} \ - -DSEMBA_FDTD_ENABLE_HDF=${{matrix.hdf}} \ - -DSEMBA_FDTD_ENABLE_MTLN=${{matrix.mtln}} - cmake --build build -j - - - name: Run fdtd unit tests - timeout-minutes: 30 - run: | - build/bin/fdtd_tests - - - name: Install python wrapper requirements - run: | - python -m pip install -r requirements.txt - - - name: Run non-mtln and non-hdf wrapper tests - if: matrix.mtln=='No' || matrix.hdf=='No' - run: python -m pytest -m 'not mtln and not hdf5' test/ - - \ No newline at end of file diff --git a/.github/workflows/ubuntu.yml b/.github/workflows/ubuntu.yml index 6264c284..fff1bbcd 100644 --- a/.github/workflows/ubuntu.yml +++ b/.github/workflows/ubuntu.yml @@ -27,12 +27,12 @@ jobs: include: - compiler: {name: 'intel-classic', version: '2021.10'} - build-type: "Release" + build-type: ["Debug", "Release"] mpi: "No" mtln: "No" hdf: "Yes" - compiler: {name: 'nvidia-hpc', version: '24.5'} - build-type: "Release" + build-type: ["Debug", "Release"] mpi: "No" mtln: "No" hdf: "No" @@ -85,11 +85,9 @@ jobs: python -m pip install -r requirements.txt - name: Run all wrapper tests - if: matrix.mtln=='Yes' - run: python -m pytest test/ - - - name: Run non-mtln wrapper tests - if: matrix.mtln=='No' + env: + SEMBA_FDTD_ENABLE_MTLN: ${{ matrix.mtln }} run: python -m pytest -m 'not mtln' test/ + diff --git a/.github/workflows/windows-intelLLVM.yml b/.github/workflows/windows-intelLLVM.yml index ad966f49..32be3a69 100644 --- a/.github/workflows/windows-intelLLVM.yml +++ b/.github/workflows/windows-intelLLVM.yml @@ -28,7 +28,7 @@ jobs: mtln: "No" hdf: "Yes" - name: windows-intelLLVM ${{matrix.build-type}} - mpi ${{matrix.mpi}} - mtln ${{matrix.mtln}} + name: ${{matrix.build-type}}-mpi(${{matrix.mpi}})-mtln(${{matrix.mtln}})-hdf(${{matrix.hdf}}) steps: diff --git a/pytest.ini b/pytest.ini index 098efa49..7c5346e7 100644 --- a/pytest.ini +++ b/pytest.ini @@ -2,4 +2,4 @@ markers = mtln: tests which use mtln features. codemodel: test that need xspice codemodels. - hdf5: tests that need hdf5. \ No newline at end of file + hdf: tests that need hdf5. \ No newline at end of file diff --git a/test/pyWrapper/test_full_system.py b/test/pyWrapper/test_full_system.py index 08730c2b..2553d0d7 100644 --- a/test/pyWrapper/test_full_system.py +++ b/test/pyWrapper/test_full_system.py @@ -1,6 +1,7 @@ from utils import * import pytest +@no_mtln_skip @pytest.mark.mtln def test_shieldedPair(tmp_path): fn = CASE_FOLDER + 'shieldedPair/shieldedPair.fdtd.json' @@ -31,6 +32,7 @@ def test_shieldedPair(tmp_path): p_solved = Probe(probe_files[i]) assert np.allclose(p_expected[i].df.to_numpy()[:,0:4], p_solved.df.to_numpy()[:,0:4], rtol = 5e-2, atol=0.2) +@no_mtln_skip @pytest.mark.mtln def test_coated_antenna(tmp_path): fn = CASE_FOLDER + 'coated_antenna/coated_antenna.fdtd.json' @@ -67,6 +69,7 @@ def test_holland(tmp_path): p_solved = Probe(probe_files[0]) assert np.allclose(p_expected.df.to_numpy()[:,0:3], p_solved.df.to_numpy()[:,0:3], rtol = 1e-5, atol=1e-6) +@no_mtln_skip @pytest.mark.mtln def test_holland_mtln(tmp_path): fn = CASE_FOLDER + 'holland/holland1981.fdtd.json' @@ -103,8 +106,8 @@ def test_towelHanger(tmp_path): p_solved = Probe(probe_files[i]) assert np.allclose(p_expected[i].df.to_numpy()[:,0:3], p_solved.df.to_numpy()[:,0:3], rtol = 5e-2, atol=5e-2) - -@pytest.mark.hdf5 +@no_hdf_skip +@pytest.mark.hdf def test_sphere(tmp_path): fn = CASE_FOLDER + 'sphere/sphere.fdtd.json' solver = FDTD(input_filename = fn, path_to_exe=SEMBA_EXE, run_in_folder=tmp_path) diff --git a/test/pyWrapper/test_mtln_standalone.py b/test/pyWrapper/test_mtln_standalone.py index b80ac0bb..963c5b1d 100644 --- a/test/pyWrapper/test_mtln_standalone.py +++ b/test/pyWrapper/test_mtln_standalone.py @@ -1,6 +1,7 @@ from utils import * import pytest +@no_mtln_skip @pytest.mark.mtln def test_paul_8_6_square(tmp_path): case = 'paul_8_6_square' @@ -21,6 +22,7 @@ def test_paul_8_6_square(tmp_path): assert np.allclose(p_expected.df.to_numpy()[:,0:2], p_solved.df.to_numpy()[:,0:2], rtol = 0.01, atol=0.2) +@no_mtln_skip @pytest.mark.mtln def test_paul_8_6_triangle(tmp_path): case = 'paul_8_6_triangle' @@ -41,6 +43,7 @@ def test_paul_8_6_triangle(tmp_path): assert np.allclose(p_expected.df.to_numpy()[:,0:2], p_solved.df.to_numpy()[:,0:2], rtol = 0.01, atol=0.5) +@no_mtln_skip @pytest.mark.mtln def test_paul_9_6(tmp_path): case = 'paul_9_6' @@ -64,6 +67,7 @@ def test_paul_9_6(tmp_path): for i in range(2): assert np.allclose(p_expected[i].df.to_numpy()[:,:], p_solved[i].df.to_numpy()[:,:], rtol = 0.01, atol=0.5) +@no_mtln_skip @pytest.mark.mtln def test_spice_multilines_opamp(tmp_path): case = 'multilines_opamp' @@ -84,6 +88,7 @@ def test_spice_multilines_opamp(tmp_path): assert np.allclose(p_expected[0].df.to_numpy()[:-1,:], p_solved[0].df.to_numpy()[:-1,:], rtol = 0.01, atol=0.05e-3) +@no_mtln_skip @pytest.mark.mtln def test_spice_connector_diode(tmp_path): case = 'spice_connectors' @@ -108,6 +113,7 @@ def test_spice_connector_diode(tmp_path): for i in range(2): assert np.allclose(p_expected[i].df.to_numpy()[:-20,:], p_solved[i].df.to_numpy()[:-20,:], rtol = 0.01, atol=0.05e-3) +@no_mtln_skip @pytest.mark.mtln def test_line_multiline_junction(tmp_path): case = 'line_multiline_junction' @@ -131,6 +137,7 @@ def test_line_multiline_junction(tmp_path): for i in range(3): assert np.allclose(p_expected[i].df.to_numpy()[:-20,:], Probe(probe_files[i]).df.to_numpy()[:-20,:], rtol = 0.01, atol=5e-3) +@no_mtln_skip @pytest.mark.mtln @pytest.mark.codemodel def test_spice_opamp_saturation(tmp_path): diff --git a/test/pyWrapper/utils.py b/test/pyWrapper/utils.py index 441c1eb3..f744b76c 100644 --- a/test/pyWrapper/utils.py +++ b/test/pyWrapper/utils.py @@ -4,9 +4,20 @@ import numpy as np import matplotlib.pyplot as plt import pyvista as pv +import pytest from os import environ as env from sys import platform +no_mtln_skip = pytest.mark.skipif( + os.getenv("SEMBA_FDTD_ENABLE_MTLN") == "No", + reason="MTLN is not available", +) + +no_hdf_skip = pytest.mark.skipif( + os.getenv("SEMBA_FDTD_ENABLE_HDF") == "No", + reason="HDF5 is not available", +) + # Use of absolute path to avoid conflicts when changing directory. if platform == "linux": SEMBA_EXE = os.path.join(os.getcwd(), 'build', 'bin', 'semba-fdtd') From 90393292f53e3cc3d2ca4b4b66efa2e1357b0019 Mon Sep 17 00:00:00 2001 From: Luis Manuel Diaz Angulo Date: Thu, 26 Dec 2024 22:08:38 +0100 Subject: [PATCH 4/7] Minor --- .github/workflows/ubuntu.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ubuntu.yml b/.github/workflows/ubuntu.yml index fff1bbcd..2daa322f 100644 --- a/.github/workflows/ubuntu.yml +++ b/.github/workflows/ubuntu.yml @@ -27,12 +27,12 @@ jobs: include: - compiler: {name: 'intel-classic', version: '2021.10'} - build-type: ["Debug", "Release"] + build-type: "Release" mpi: "No" mtln: "No" hdf: "Yes" - compiler: {name: 'nvidia-hpc', version: '24.5'} - build-type: ["Debug", "Release"] + build-type: "Release" mpi: "No" mtln: "No" hdf: "No" From 8dad883504dbf3834250b1c928f68b1b67ae1c5b Mon Sep 17 00:00:00 2001 From: Luis Manuel Diaz Angulo Date: Thu, 26 Dec 2024 22:28:05 +0100 Subject: [PATCH 5/7] Update ubuntu.yml to enable HDF tests in the wrapper tests --- .github/workflows/ubuntu.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ubuntu.yml b/.github/workflows/ubuntu.yml index 2daa322f..7a1f1ea3 100644 --- a/.github/workflows/ubuntu.yml +++ b/.github/workflows/ubuntu.yml @@ -87,7 +87,8 @@ jobs: - name: Run all wrapper tests env: SEMBA_FDTD_ENABLE_MTLN: ${{ matrix.mtln }} - run: python -m pytest -m 'not mtln' test/ + SEMBA_FDTD_ENABLE_HDF: ${{ matrix.hdf }} + run: python -m pytest test/ 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 6/7] 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 From ce80e2c45a3c7985fb5525cc47ee23dfb50eadd0 Mon Sep 17 00:00:00 2001 From: Luis Manuel Diaz Angulo Date: Fri, 27 Dec 2024 10:13:11 +0100 Subject: [PATCH 7/7] Minor --- .github/workflows/windows-intelLLVM.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/windows-intelLLVM.yml b/.github/workflows/windows-intelLLVM.yml index 9d1f5339..1258c9dc 100644 --- a/.github/workflows/windows-intelLLVM.yml +++ b/.github/workflows/windows-intelLLVM.yml @@ -24,7 +24,8 @@ jobs: hdf: ["Yes"] include: - - build-type: "Release" + - compiler: {name: 'intel', version: '2024.0'} + build-type: "Release" mpi: "No" mtln: "No" hdf: "Yes"