updated build system
All checks were successful
BlockStorage/repertory/pipeline/head This commit looks good

This commit is contained in:
2024-08-10 12:27:47 -05:00
parent 1e854aa368
commit 52cc40b4cf
4 changed files with 73 additions and 70 deletions

View File

@ -84,19 +84,21 @@ TEST(utils_file, write_fails_for_read_only_file) {
}
}
TEST(utils_file, can_attach_file) {
for (auto idx = 0U; idx < file_type_count; ++idx) {
auto path = test::generate_test_file_name("utils_file");
auto file = idx == 0U ? utils::file::file::open_or_create_file(path)
: utils::file::thread_file::open_or_create_file(path);
auto file2 =
idx == 0U ? utils::file::file::attach_file(file->get_handle())
: utils::file::thread_file::attach_file(file->get_handle());
EXPECT_TRUE(*file);
EXPECT_TRUE(*file2);
EXPECT_EQ(file->get_path(), file2->get_path());
}
}
// TEST(utils_file, can_attach_file) {
// for (auto idx = 0U; idx < file_type_count; ++idx) {
// auto path = test::generate_test_file_name("utils_file");
// auto file = idx == 0U ? utils::file::file::open_or_create_file(path)
// :
// utils::file::thread_file::open_or_create_file(path);
// auto file2 =
// idx == 0U ? utils::file::file::attach_file(file->get_handle())
// :
// utils::file::thread_file::attach_file(file->get_handle());
// EXPECT_TRUE(*file);
// EXPECT_TRUE(*file2);
// EXPECT_EQ(file->get_path(), file2->get_path());
// }
// }
#if defined(PROJECT_ENABLE_JSON)
TEST(utils_file, read_and_write_json_file) {