Skip to content

Commit 3f901c9

Browse files
committed
Attempting to enable CI pygeosx tests
1 parent 085663a commit 3f901c9

File tree

2 files changed

+14
-2
lines changed

2 files changed

+14
-2
lines changed

scripts/ci_build_and_test_in_container.sh

+13-1
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,7 @@ args=$(or_die getopt -a -o h --long build-exe-only,cmake-build-type:,code-covera
7373
# Variables with default values
7474
BUILD_EXE_ONLY=false
7575
GEOSX_INSTALL_SCHEMA=true
76+
BUILD_PYGEOSX=true
7677
HOST_CONFIG="host-configs/environment.cmake"
7778
RUN_UNIT_TESTS=true
7879
RUN_INTEGRATED_TESTS=false
@@ -108,6 +109,7 @@ do
108109
--no-run-unit-tests) RUN_UNIT_TESTS=false; shift;;
109110
--nproc) NPROC=$2; shift 2;;
110111
--repository) GEOS_SRC_DIR=$2; shift 2;;
112+
--build_pygeosx) BUILD_PYGEOSX=true; shift;;
111113
--run-integrated-tests) RUN_INTEGRATED_TESTS=true; shift;;
112114
--upload-test-baselines) UPLOAD_TEST_BASELINES=true; shift;;
113115
--code-coverage) CODE_COVERAGE=true; shift;;
@@ -201,6 +203,15 @@ if [[ "${CODE_COVERAGE}" = true ]]; then
201203
fi
202204

203205

206+
PYGEOSX_ARGS=""
207+
if [[ "${BUILD_PYGEOSX}" = true ]]; then
208+
echo "Enabling pygeosx."
209+
or_die apt-get install -y python3-dev
210+
211+
PYTHON_EXEC=$(which python3)
212+
PYGEOSX_ARGS="-DENABLE_PYGEOSX=ON -DPython3_EXECUTABLE=$PYTHON_EXEC"
213+
fi
214+
204215

205216
# The -DBLT_MPI_COMMAND_APPEND="--allow-run-as-root;--oversubscribe" option is added for OpenMPI.
206217
#
@@ -226,7 +237,8 @@ or_die python3 scripts/config-build.py \
226237
-DGEOSX_INSTALL_SCHEMA=${GEOSX_INSTALL_SCHEMA} \
227238
-DENABLE_COVERAGE=$([[ "${CODE_COVERAGE}" = true ]] && echo 1 || echo 0) \
228239
${SCCACHE_CMAKE_ARGS} \
229-
${ATS_CMAKE_ARGS}
240+
${ATS_CMAKE_ARGS} \
241+
$PYGEOSX_ARGS
230242

231243
# The configuration step is now over, we can now move to the build directory for the build!
232244
or_die cd ${GEOSX_BUILD_DIR}

src/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -235,7 +235,7 @@ install( FILES ${CMAKE_BINARY_DIR}/schema.xsd
235235
# message(WARNING "Temporarily changing the geosPythonBranch to cusini/fix-streak-cert-fail")
236236
# set(GEOS_PYTHON_PACKAGES_BRANCH "cusini/fix-streak-cert-fail" CACHE STRING "" FORCE)
237237
message(WARNING "Temporarily changing the geosPythonBranch to feature/sherman/addPygeosxIntegratedTests")
238-
set(GEOS_PYTHON_PACKAGES_BRANCH "cusini/fix-streak-cert-fail" CACHE STRING "" FORCE)
238+
set(GEOS_PYTHON_PACKAGES_BRANCH "feature/sherman/addPygeosxIntegratedTests" CACHE STRING "" FORCE)
239239

240240

241241
if ( Python3_EXECUTABLE )

0 commit comments

Comments
 (0)