Update test_file_helper.cpp

This commit is contained in:
Gabi Melman 2021-12-10 22:31:08 +02:00 committed by gabime
parent 8715f51c61
commit 9abcf38b90

View File

@ -145,13 +145,13 @@ TEST_CASE("file_event_handlers", "[file_helper]")
events.clear();
helper.close();
REQUIRE(events == std::vector<flags>{flags::before_close, flags::after_close});
REQUIRE(file_contents(test_filename) == "after_open\nbefore_close\n");
REQUIRE(file_contents(TEST_FILENAME) == "after_open\nbefore_close\n");
helper.reopen(true);
events.clear();
}
// make sure that the file_helper destrcutor calls the close callbacks if needed
REQUIRE(events == std::vector<flags>{flags::before_close, flags::after_close});
REQUIRE(file_contents(test_filename) == "after_open\nbefore_close\n");
REQUIRE(file_contents(TEST_FILENAME) == "after_open\nbefore_close\n");
}