Update test_node.cpp

This commit is contained in:
Lew Rossman
2019-04-18 07:39:39 -04:00
parent cc22eefeae
commit 6b0e421a39

View File

@@ -23,9 +23,9 @@ BOOST_FIXTURE_TEST_CASE(test_adddelete_node, FixtureInitClose)
{ {
int index; int index;
error = EN_addnode(ph, (char *)"N2", EN_JUNCTION); error = EN_addnode(ph, (char *)"N2", EN_JUNCTION, &index);
BOOST_REQUIRE(error == 0); BOOST_REQUIRE(error == 0);
error = EN_addnode(ph, (char *)"N3", EN_RESERVOIR); error = EN_addnode(ph, (char *)"N3", EN_RESERVOIR, &index);
BOOST_REQUIRE(error == 0); BOOST_REQUIRE(error == 0);
error = EN_getnodeindex(ph, (char *)"N2", &index); error = EN_getnodeindex(ph, (char *)"N2", &index);
@@ -33,7 +33,7 @@ BOOST_FIXTURE_TEST_CASE(test_adddelete_node, FixtureInitClose)
error = EN_deletenode(ph, index, EN_UNCONDITIONAL); error = EN_deletenode(ph, index, EN_UNCONDITIONAL);
BOOST_REQUIRE(error == 0); BOOST_REQUIRE(error == 0);
error = EN_addnode(ph, (char *)"N4", EN_TANK); error = EN_addnode(ph, (char *)"N4", EN_TANK, &index);
BOOST_REQUIRE(error == 0); BOOST_REQUIRE(error == 0);
error = EN_getnodeindex(ph, (char *)"N4", &index); error = EN_getnodeindex(ph, (char *)"N4", &index);
@@ -51,16 +51,16 @@ BOOST_FIXTURE_TEST_CASE(test_node_validate_id, FixtureInitClose)
{ {
int index; int index;
error = EN_addnode(ph, (char *)"N2", EN_JUNCTION); error = EN_addnode(ph, (char *)"N2", EN_JUNCTION, &index);
BOOST_REQUIRE(error == 0); BOOST_REQUIRE(error == 0);
error = EN_addnode(ph, (char *)"N 3", EN_JUNCTION); error = EN_addnode(ph, (char *)"N 3", EN_JUNCTION, &index);
BOOST_REQUIRE(error == 252); BOOST_REQUIRE(error == 252);
error = EN_addnode(ph, (char *)"N\"3", EN_JUNCTION); error = EN_addnode(ph, (char *)"N\"3", EN_JUNCTION, &index);
BOOST_REQUIRE(error == 252); BOOST_REQUIRE(error == 252);
error = EN_addnode(ph, (char *)"N;3", EN_JUNCTION); error = EN_addnode(ph, (char *)"N;3", EN_JUNCTION, &index);
BOOST_REQUIRE(error == 252); BOOST_REQUIRE(error == 252);
EN_getnodeindex(ph, (char *)"N2", &index); EN_getnodeindex(ph, (char *)"N2", &index);