Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 3 additions & 7 deletions .github/workflows/cmake-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ jobs:
if: matrix.python_api == 'ON'
run: |
sudo apt-get install -yq python3 python3-pip python3-dev python3-pybind11 pybind11-dev
pip3 install numpy
pip3 install numpy pytest

- uses: actions/checkout@v4

Expand Down Expand Up @@ -288,12 +288,8 @@ jobs:
run: |
export PYTHONPATH=${{ runner.temp }}/build-pcms/install/lib/python3.12/site-packages:$PYTHONPATH
export PYTHONPATH=${{ runner.temp }}/build-omega_h/install/lib/python/dist-packages:$PYTHONPATH
cd ${{ github.workspace }}/src/pcms/pythonapi
python3 test_file_io.py
python3 test_omega_h_field.py
python3 test_uniform_grid_field.py
python3 test_field_copy.py
python3 test_mls_interpolation.py
cd ${{ github.workspace }}
pytest -v --tb=short -p no:cacheprovider

- name: Test PCMS Installation
if: matrix.python_api == 'OFF'
Expand Down
10 changes: 8 additions & 2 deletions .github/workflows/self-hosted.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ jobs:
#module load openblas/0.3.23-wqm7iud
module load netlib-lapack/3.11.0-b22mgwg #netlib-lapack includes blas
module load netlib-scalapack/2.2.0-fzd4jvl
module load python py-pybind11 py-pytest py-numpy
set -e
EOF

Expand Down Expand Up @@ -98,13 +99,13 @@ jobs:
cmake --build $bdir -j 4
ctest --test-dir $bdir --output-on-failure

# Build pcms with PETSc
# Build pcms with PETSc and python enabled
cmake -S ${{github.workspace}}/pcms_${{ github.event.id }} -B $bdir \
-DCMAKE_CXX_COMPILER=`which mpicxx` \
-DCMAKE_C_COMPILER=`which mpicc` \
-DCMAKE_Fortran_COMPILER=`which mpifort`\
-DPCMS_TIMEOUT=20 \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_BUILD_TYPE=DEBUG \
-DCatch2_DIR=$DEPENDENCY_DIR/Catch2/install/lib64/cmake/Catch2/ \
-Dmeshfields_DIR=$DEPENDENCY_DIR/${DEVICE_ARCH}/meshFields/install/lib64/cmake/meshfields \
-DOmega_h_DIR=$DEPENDENCY_DIR/${DEVICE_ARCH}/omega_h/install/lib64/cmake/Omega_h/ \
Expand All @@ -116,6 +117,7 @@ jobs:
-DKokkos_DIR=$DEPENDENCY_DIR/${DEVICE_ARCH}/kokkos/install/lib64/cmake/Kokkos/ \
-DKokkosKernels_DIR=$DEPENDENCY_DIR/${DEVICE_ARCH}/kokkos-kernels/install/lib64/cmake/KokkosKernels/ \
-DBUILD_TESTING=ON \
-DPCMS_ENABLE_Python=ON \
-DPCMS_ENABLE_PETSC=ON \
-DPETSC_ARCH="" \
-DPETSC_DIR=$DEPENDENCY_DIR/${DEVICE_ARCH}/petsc/install \
Expand All @@ -124,6 +126,10 @@ jobs:
cmake --build $bdir -j 4
ctest --test-dir $bdir --output-on-failure

export PYTHONPATH=$DEPENDENCY_DIR/${DEVICE_ARCH}/omega_h/install/lib64/python3.11/site-packages:$bdir/src/pcms/pythonapi:$PYTHONPATH
export LD_LIBRARY_PATH=$DEPENDENCY_DIR/${DEVICE_ARCH}/omega_h/install/lib64:$LD_LIBRARY_PATH
pytest -v -p no:cacheprovider ${{github.workspace}}/pcms_${{ github.event.id }}/test/python


- name: Save Result Link
if: ${{ !cancelled() }} #prepare report unless the job was cancelled
Expand Down
7 changes: 7 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,10 @@ version = "0.4.0"

[tool.scikit-build.cmake.define]
PCMS_ENABLE_Python = true

[tool.pytest.ini_options]
testpaths = ["test/python"]
python_files = "test_*.py"
python_classes = "Test*"
python_functions = "test_*"
addopts = "--strict-markers"
83 changes: 0 additions & 83 deletions src/pcms/pythonapi/test_field_copy.py

This file was deleted.

Loading
Loading