added keyword DYNAMICR.

added keyword DYNAMICR.
This commit is contained in:
Steinar Foss
2019-12-16 15:24:54 +01:00
parent 43116d3c45
commit 01b62e4617
3 changed files with 33 additions and 0 deletions

View File

@@ -0,0 +1,4 @@
{"name" : "DYNAMICR",
"sections" : ["SOLUTION", "SCHEDULE"],
"comment" : "Note: this only makes it possible to parse files with DYNAMICR keywords. Apart from that, this keyword is not supported.",
"code" : {"end" : "ENDDYN"}}

View File

@@ -160,6 +160,7 @@ set( keywords
000_Eclipse100/D/DUALPORO
000_Eclipse100/D/DUMPFLUX
000_Eclipse100/D/DUMPCUPL
000_Eclipse100/D/DYNAMICR
000_Eclipse100/D/DYNRDIMS
000_Eclipse100/D/DX
000_Eclipse100/D/DXV

View File

@@ -1970,6 +1970,34 @@ STONE
}
}
BOOST_AUTO_TEST_CASE(ParseDynamicr) {
const auto deck_string = std::string { R"(RUNSPEC
FIELD
SOLUTION
DYNAMICR
FIPYYY
1 /
"IN" FIPXXX 1 /
/
FIPYYY
2 /
"ALL" FIPXXX 2 FIPXXX 3 /
/
FIPYYY
3 /
BOIP <= 500000 /
/ENDDYN
SCHEDULE
GCUTBACK
G1 0.6 3* 0.9 LIQ /
/
)"};
Parser parser;
auto deck = parser.parseString(deck_string);
BOOST_CHECK( deck.hasKeyword("GCUTBACK") );
}
BOOST_AUTO_TEST_CASE(ParseRSConst) {
// Check that parsing RSCONST does not bleed into next keyword.