Python code must be properly terminated

This commit is contained in:
Joakim Hove
2020-01-09 09:26:35 +01:00
parent 6199b81e60
commit f3797e8877
2 changed files with 1 additions and 24 deletions

View File

@@ -49,13 +49,6 @@ PYACTION Her comes an ignored comment
const std::string deck_string2 = R"(
SCHEDULE
PYACTION
)" + input_code;
const std::string deck_string3 = R"(
SCHEDULE
PYACTION -- Comment
)" + input_code + "PYEND" + "\nGRID";
@@ -70,11 +63,6 @@ PYACTION -- Comment
auto deck = parser.parseString(deck_string2);
const auto& parsed_code = deck.getKeyword("PYACTION").getRecord(0).getItem("code").get<std::string>(0);
BOOST_CHECK_EQUAL(parsed_code, input_code);
}
{
auto deck = parser.parseString(deck_string3);
const auto& parsed_code = deck.getKeyword("PYACTION").getRecord(0).getItem("code").get<std::string>(0);
BOOST_CHECK_EQUAL(parsed_code, input_code);
BOOST_CHECK( deck.hasKeyword("GRID"));
}