Skip to content

Commit e48f4e8

Browse files
[Tests][CAS]Fix ActionCacheTest without OnDiskCAS support
Disable ActionCacheTest that depends on OnDiskCAS when OnDiskCAS is not available.
1 parent 3490111 commit e48f4e8

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

llvm/unittests/CAS/ActionCacheTest.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,7 @@ TEST_P(CASTest, ActionCacheRewrite) {
7474
ASSERT_THAT_ERROR(Cache->put(*ID1, *ID1), Succeeded());
7575
}
7676

77+
#if LLVM_ENABLE_ONDISK_CAS
7778
TEST(OnDiskActionCache, ActionCacheResultInvalid) {
7879
unittest::TempDir Temp("on-disk-cache", /*Unique=*/true);
7980
std::unique_ptr<ObjectStore> CAS1 = createInMemoryCAS();
@@ -106,6 +107,7 @@ TEST(OnDiskActionCache, ActionCacheResultInvalid) {
106107
// Write a different value will cause error.
107108
ASSERT_THAT_ERROR(Cache2->put(*ID3, *ID3), Failed());
108109
}
110+
#endif
109111

110112
TEST_P(CASTest, ActionCacheAsync) {
111113
std::shared_ptr<ObjectStore> CAS = createObjectStore();

0 commit comments

Comments
 (0)