changed: add EquilRecord::serializationTestObject

and use this in Equil::serializationTestObject()
This commit is contained in:
Arne Morten Kvarving
2023-08-16 09:56:34 +02:00
parent 89f59e0050
commit a93e285552
2 changed files with 8 additions and 1 deletions

View File

@@ -26,6 +26,8 @@ namespace Opm {
EquilRecord( double datum_depth_arg, double datum_depth_pc_arg, double woc_depth, double woc_pc, double goc_depth, double goc_pc, bool live_oil_init, bool wet_gas_init, int target_accuracy, bool humid_gas_init);
explicit EquilRecord(const DeckRecord& record);
static EquilRecord serializationTestObject();
bool operator==(const EquilRecord& data) const;
template<class Serializer>

View File

@@ -51,6 +51,11 @@ namespace Opm {
, humid_gas_init_proc(record.getItem<ParserKeywords::EQUIL::BLACK_OIL_INIT_HG>().get<int>(0) <= 0)
{}
EquilRecord EquilRecord::serializationTestObject()
{
return EquilRecord{1.0, 2.0, 3.0, 4.0, 5.0, 6.0, true, false, 1, false};
}
double EquilRecord::datumDepth() const {
return this->datum_depth;
}
@@ -120,7 +125,7 @@ namespace Opm {
Equil Equil::serializationTestObject()
{
Equil result;
result.m_records = {{1.0, 2.0, 3.0, 4.0, 5.0, 6.0, true, false, 1, false}};
result.m_records = {EquilRecord::serializationTestObject()};
return result;
}