Added barebones test for dynamic fluid system

This commit is contained in:
Kjetil Olsen Lye 2025-02-12 21:46:06 +01:00
parent b99b606575
commit 544725f0fb
3 changed files with 32 additions and 0 deletions

View File

@ -740,6 +740,7 @@ if(CUDA_FOUND)
gpu_resources gpu_resources
gpu_smart_pointers gpu_smart_pointers
is_gpu_pointer is_gpu_pointer
blackoilfluidsystemgpu
PROPERTIES LABELS ${gpu_label}) PROPERTIES LABELS ${gpu_label})
endif() endif()

View File

@ -482,6 +482,8 @@ if (HAVE_CUDA)
ADD_CUDA_OR_HIP_FILE(TEST_SOURCE_FILES tests test_gpu_smart_pointers.cu) ADD_CUDA_OR_HIP_FILE(TEST_SOURCE_FILES tests test_gpu_smart_pointers.cu)
ADD_CUDA_OR_HIP_FILE(TEST_SOURCE_FILES tests test_gpu_resources.cu) ADD_CUDA_OR_HIP_FILE(TEST_SOURCE_FILES tests test_gpu_resources.cu)
ADD_CUDA_OR_HIP_FILE(TEST_SOURCE_FILES tests test_is_gpu_pointer.cpp) ADD_CUDA_OR_HIP_FILE(TEST_SOURCE_FILES tests test_is_gpu_pointer.cpp)
ADD_CUDA_OR_HIP_FILE(TEST_SOURCE_FILES tests test_blackoilfluidsystemgpu.cu)
# for loop providing the flag --expt-relaxed-constexpr to fix some cuda issues with constexpr # for loop providing the flag --expt-relaxed-constexpr to fix some cuda issues with constexpr
if(NOT CONVERT_CUDA_TO_HIP) if(NOT CONVERT_CUDA_TO_HIP)
@ -489,6 +491,7 @@ if (HAVE_CUDA)
tests/gpuistl/test_gpu_ad.cu tests/gpuistl/test_gpu_ad.cu
tests/gpuistl/test_gpu_linear_two_phase_material.cu tests/gpuistl/test_gpu_linear_two_phase_material.cu
tests/gpuistl/test_gpuPvt.cu tests/gpuistl/test_gpuPvt.cu
tests/gpuistl/test_blackoilfluidsystemgpu.cu
) )
foreach(file ${CU_FILES_NEEDING_RELAXED_CONSTEXPR}) foreach(file ${CU_FILES_NEEDING_RELAXED_CONSTEXPR})

View File

@ -0,0 +1,28 @@
/*
Copyright 2025 Equinor ASA
This file is part of the Open Porous Media project (OPM).
OPM is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
OPM is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with OPM. If not, see <http://www.gnu.org/licenses/>.
*/
#define BOOST_TEST_MODULE TestBlackOilFluidSystemGPU
#include <config.h>
#include <boost/test/unit_test.hpp>
#include <opm/material/fluidsystems/BlackOilFluidSystemDynamic.hpp>
BOOST_AUTO_TEST_CASE(TestDynamicCreationCPU) {
Opm::BlackOilFluidSystemDynamic<double> fluidSystem;
}