Skip to content

Commit

Permalink
skip file size tests based on C++ version
Browse files Browse the repository at this point in the history
  • Loading branch information
barnasm1 committed Jan 16, 2025
1 parent 71e2206 commit c8bdb3b
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/core/tests/file_util.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -571,8 +571,10 @@ TEST_F(FileUtilTest, FileSizeNonExistentFileTest) {
}

TEST_F(FileUtilTest, EmptyFileSizeTest) {
EXPECT_EQ(ov::util::file_size("test_file_0.txt"s), 0);
#ifdef OPENVINO_CPP_VER_AT_LEAST_20
EXPECT_EQ(ov::util::file_size(u8"test_file_0.txt"), 0);
#endif
EXPECT_EQ(ov::util::file_size("test_file_0.txt"s), 0);
EXPECT_EQ(ov::util::file_size(u"test_file_0.txt"), 0);
EXPECT_EQ(ov::util::file_size(U"test_file_0.txt"), 0);
EXPECT_EQ(ov::util::file_size(L"test_file_0.txt"), 0);
Expand All @@ -598,8 +600,10 @@ TEST_F(FileUtilTest, LargeFileSizeTest) {

#ifdef OPENVINO_ENABLE_UNICODE_PATH_SUPPORT
TEST_F(FileUtilTest, u8FileSizeTest) {
EXPECT_EQ(ov::util::file_size("这是_u8_.txt"s), 21);
# ifdef OPENVINO_CPP_VER_AT_LEAST_20
EXPECT_EQ(ov::util::file_size(u8"这是_u8_.txt"), 21);
# endif
EXPECT_EQ(ov::util::file_size("这是_u8_.txt"s), 21);
EXPECT_EQ(ov::util::file_size(u"这是_u8_.txt"), 21);
EXPECT_EQ(ov::util::file_size(U"这是_u8_.txt"), 21);
EXPECT_EQ(ov::util::file_size(L"这是_u8_.txt"), 21);
Expand Down

0 comments on commit c8bdb3b

Please sign in to comment.