Skip to content

Commit

Permalink
test yaml error with mark
Browse files Browse the repository at this point in the history
  • Loading branch information
payetvin committed Dec 31, 2024
1 parent e80708b commit cbe01b2
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions src/tests/src/solver/modeler/loadFiles/testLoadModelerFiles.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,21 @@ BOOST_FIXTURE_TEST_CASE(incorrect_library, FixtureLoadFile)
BOOST_CHECK_THROW(Antares::Solver::LoadFiles::loadLibraries(studyPath), std::runtime_error);
}

BOOST_FIXTURE_TEST_CASE(incorrect_library2, FixtureLoadFile)
{
std::ofstream libStream(libraryDirPath / "simple.yml");
libStream << R"(
library:
id: std
port-types: []
- id: generator
description: A basic generator model
)";
libStream.close();
BOOST_CHECK_THROW(Antares::Solver::LoadFiles::loadLibraries(studyPath), std::runtime_error);
}

BOOST_FIXTURE_TEST_CASE(read_several_lib_file, FixtureLoadFile)
{
std::ofstream libStream(libraryDirPath / "simple.yml");
Expand Down

0 comments on commit cbe01b2

Please sign in to comment.