mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
add mpi serialization for GConSale
This commit is contained in:
@@ -37,6 +37,7 @@
|
||||
#include <opm/parser/eclipse/EclipseState/IOConfig/IOConfig.hpp>
|
||||
#include <opm/parser/eclipse/EclipseState/IOConfig/RestartConfig.hpp>
|
||||
#include <opm/parser/eclipse/EclipseState/Schedule/Events.hpp>
|
||||
#include <opm/parser/eclipse/EclipseState/Schedule/Group/GConSale.hpp>
|
||||
#include <opm/parser/eclipse/EclipseState/Schedule/Group/Group.hpp>
|
||||
#include <opm/parser/eclipse/EclipseState/Schedule/Group/GuideRateModel.hpp>
|
||||
#include <opm/parser/eclipse/EclipseState/Schedule/MessageLimits.hpp>
|
||||
@@ -1902,6 +1903,37 @@ BOOST_AUTO_TEST_CASE(GuideRateConfig)
|
||||
}
|
||||
|
||||
|
||||
BOOST_AUTO_TEST_CASE(GConSaleGroup)
|
||||
{
|
||||
#ifdef HAVE_MPI
|
||||
Opm::GConSale::GCONSALEGroup val1{Opm::UDAValue(1.0),
|
||||
Opm::UDAValue(2.0),
|
||||
Opm::UDAValue(3.0),
|
||||
Opm::GConSale::MaxProcedure::PLUG,
|
||||
4.0, Opm::UnitSystem()};
|
||||
auto val2 = PackUnpack(val1);
|
||||
BOOST_CHECK(std::get<1>(val2) == std::get<2>(val2));
|
||||
BOOST_CHECK(val1 == std::get<0>(val2));
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
BOOST_AUTO_TEST_CASE(GConSale)
|
||||
{
|
||||
#ifdef HAVE_MPI
|
||||
Opm::GConSale::GCONSALEGroup group{Opm::UDAValue(1.0),
|
||||
Opm::UDAValue(2.0),
|
||||
Opm::UDAValue(3.0),
|
||||
Opm::GConSale::MaxProcedure::PLUG,
|
||||
4.0, Opm::UnitSystem()};
|
||||
Opm::GConSale val1({{"test1", group}, {"test2", group}});
|
||||
auto val2 = PackUnpack(val1);
|
||||
BOOST_CHECK(std::get<1>(val2) == std::get<2>(val2));
|
||||
BOOST_CHECK(val1 == std::get<0>(val2));
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
bool init_unit_test_func()
|
||||
{
|
||||
return true;
|
||||
|
||||
Reference in New Issue
Block a user