EclGenericProblem: remove unused time steppping parameters

and remove some hidden duplicates
This commit is contained in:
Arne Morten Kvarving
2023-08-02 15:27:51 +02:00
parent c1e1b0ee70
commit 13b0e14f18
8 changed files with 19 additions and 46 deletions

View File

@@ -57,6 +57,14 @@
#include <algorithm>
namespace Opm::Properties {
namespace TTag {
struct TestRestartTypeTag {
using InheritsFrom = std::tuple<EbosTypeTag, FlowTimeSteppingParameters>;
};
}
}
template<class T>
std::tuple<T,int,int> PackUnpack(T& in)
{
@@ -427,11 +435,12 @@ namespace {
struct AquiferFixture {
AquiferFixture() {
using TT = Opm::Properties::TTag::EbosTypeTag;
using TT = Opm::Properties::TTag::TestRestartTypeTag;
const char* argv[] = {
"test_RestartSerialization",
"--ecl-deck-file-name=GLIFT1.DATA"
};
Opm::AdaptiveTimeSteppingEbos<TT>::registerParameters();
Opm::setupParameters_<TT>(2, argv, /*registerParams=*/true);
Opm::EclGenericVanguard::setCommunication(std::make_unique<Opm::Parallel::Communication>());
}
@@ -444,7 +453,7 @@ BOOST_GLOBAL_FIXTURE(AquiferFixture);
#define TEST_FOR_AQUIFER(TYPE) \
BOOST_AUTO_TEST_CASE(TYPE) \
{ \
using TT = Opm::Properties::TTag::EbosTypeTag; \
using TT = Opm::Properties::TTag::TestRestartTypeTag; \
Opm::EclGenericVanguard::readDeck("GLIFT1.DATA"); \
using Simulator = Opm::GetPropType<TT, Opm::Properties::Simulator>; \
Simulator sim; \
@@ -465,7 +474,7 @@ TEST_FOR_AQUIFER(AquiferFetkovich)
BOOST_AUTO_TEST_CASE(AquiferNumerical)
{
using TT = Opm::Properties::TTag::EbosTypeTag;
using TT = Opm::Properties::TTag::TestRestartTypeTag;
Opm::EclGenericVanguard::readDeck("GLIFT1.DATA");
using Simulator = Opm::GetPropType<TT, Opm::Properties::Simulator>;
Simulator sim;
@@ -483,7 +492,7 @@ BOOST_AUTO_TEST_CASE(AquiferNumerical)
BOOST_AUTO_TEST_CASE(AquiferConstantFlux)
{
using TT = Opm::Properties::TTag::EbosTypeTag;
using TT = Opm::Properties::TTag::TestRestartTypeTag;
Opm::EclGenericVanguard::readDeck("GLIFT1.DATA");
using Simulator = Opm::GetPropType<TT, Opm::Properties::Simulator>;
Simulator sim;

View File

@@ -82,7 +82,7 @@ namespace TTag {
struct TestEquilTypeTag {
using InheritsFrom = std::tuple<FlowModelParameters, EclBaseProblem, BlackOilModel>;
using InheritsFrom = std::tuple<FlowTimeSteppingParameters, FlowModelParameters, EclBaseProblem, BlackOilModel>;
};
struct TestEquilVapwatTypeTag {
using InheritsFrom = std::tuple<FlowModelParameters, EclBaseProblem, BlackOilModel>;
@@ -239,6 +239,7 @@ struct EquilFixture {
#endif
Opm::EclGenericVanguard::setCommunication(std::make_unique<Opm::Parallel::Communication>());
Opm::BlackoilModelParametersEbos<TypeTag>::registerParameters();
Opm::AdaptiveTimeSteppingEbos<TypeTag>::registerParameters();
Opm::Parameters::registerParam<TypeTag, bool>("EnableTerminalOutput",
"EnableTerminalOutput",
Opm::getPropValue<TypeTag, Opm::Properties::EnableTerminalOutput>(),

View File

@@ -67,7 +67,7 @@
namespace Opm::Properties {
namespace TTag {
struct TestGliftTypeTag {
using InheritsFrom = std::tuple<EbosTypeTag>;
using InheritsFrom = std::tuple<EbosTypeTag, FlowTimeSteppingParameters>;
};
}
}
@@ -86,6 +86,7 @@ initSimulator(const char *filename)
filename_arg.c_str()
};
Opm::AdaptiveTimeSteppingEbos<TypeTag>::registerParameters();
Opm::setupParameters_<TypeTag>(/*argc=*/sizeof(argv)/sizeof(argv[0]), argv, /*registerParams=*/true);
Opm::EclGenericVanguard::readDeck(filename);