Added struct ParseMode to control parse behaviour.
- Introduce a very simple class ParseMode which will become a simple value object which can be used to control the behavior when errors and inconsistencies are encountered in the parse and EclipseState construction phases. - Added ParseMode instance as second argument to all parseXXX() methods.
This commit is contained in:
@@ -25,6 +25,7 @@
|
||||
#include <opm/parser/eclipse/Deck/Deck.hpp>
|
||||
|
||||
#include <opm/parser/eclipse/Parser/Parser.hpp>
|
||||
#include <opm/parser/eclipse/Parser/ParseMode.hpp>
|
||||
#include <opm/parser/eclipse/Parser/ParserRecord.hpp>
|
||||
#include <opm/parser/eclipse/Parser/ParserIntItem.hpp>
|
||||
#include <opm/parser/eclipse/Parser/ParserStringItem.hpp>
|
||||
@@ -40,7 +41,7 @@ BOOST_AUTO_TEST_CASE( parse_TITLE_OK ) {
|
||||
ParserPtr parser(new Parser());
|
||||
boost::filesystem::path fileWithTitleKeyword("testdata/integration_tests/TITLE/TITLE1.txt");
|
||||
|
||||
DeckPtr deck = parser->parseFile(fileWithTitleKeyword.string());
|
||||
DeckPtr deck = parser->parseFile(fileWithTitleKeyword.string(), ParseMode());
|
||||
|
||||
BOOST_CHECK_EQUAL(size_t(2), deck->size());
|
||||
BOOST_CHECK_EQUAL (true, deck->hasKeyword("TITLE"));
|
||||
|
||||
Reference in New Issue
Block a user