forked from OSchip/llvm-project
[Support] Silence warning in Path unittests when compiling with clang-cl
warning: comparison of integers of different signs: 'const unsigned long long' and 'const int' [-Wsign-compare]
This commit is contained in:
parent
e10af89d99
commit
c1f8595fe5
|
@ -1895,7 +1895,7 @@ TEST_F(FileSystemTest, widenPath) {
|
||||||
// Result should not start with the long path prefix.
|
// Result should not start with the long path prefix.
|
||||||
EXPECT_TRUE(std::wmemcmp(Result.data(), LongPathPrefix.c_str(),
|
EXPECT_TRUE(std::wmemcmp(Result.data(), LongPathPrefix.c_str(),
|
||||||
LongPathPrefix.size()) != 0);
|
LongPathPrefix.size()) != 0);
|
||||||
EXPECT_EQ(Result.size(), MAX_PATH - 1);
|
EXPECT_EQ(Result.size(), (size_t)MAX_PATH - 1);
|
||||||
|
|
||||||
// Add another Pi to exceed the MAX_PATH limit.
|
// Add another Pi to exceed the MAX_PATH limit.
|
||||||
Input += Pi;
|
Input += Pi;
|
||||||
|
@ -1921,7 +1921,7 @@ TEST_F(FileSystemTest, widenPath) {
|
||||||
// Result should not start with the long path prefix.
|
// Result should not start with the long path prefix.
|
||||||
EXPECT_TRUE(std::wmemcmp(Result.data(), LongPathPrefix.c_str(),
|
EXPECT_TRUE(std::wmemcmp(Result.data(), LongPathPrefix.c_str(),
|
||||||
LongPathPrefix.size()) != 0);
|
LongPathPrefix.size()) != 0);
|
||||||
EXPECT_EQ(Result.size(), MAX_PATH - 1);
|
EXPECT_EQ(Result.size(), (size_t)MAX_PATH - 1);
|
||||||
|
|
||||||
// Extend the directory name so the input exceeds the MAX_PATH limit.
|
// Extend the directory name so the input exceeds the MAX_PATH limit.
|
||||||
DirName += DirChar;
|
DirName += DirChar;
|
||||||
|
|
Loading…
Reference in New Issue