diff options
Diffstat (limited to 'test')
-rw-r--r-- | test/buildtool/crypto/hasher.test.cpp | 4 | ||||
-rw-r--r-- | test/buildtool/storage/large_object_cas.test.cpp | 20 |
2 files changed, 12 insertions, 12 deletions
diff --git a/test/buildtool/crypto/hasher.test.cpp b/test/buildtool/crypto/hasher.test.cpp index 8414cc81..8ace48ce 100644 --- a/test/buildtool/crypto/hasher.test.cpp +++ b/test/buildtool/crypto/hasher.test.cpp @@ -19,9 +19,9 @@ #include "catch2/catch_test_macros.hpp" -template <Hasher::HashType type> +template <Hasher::HashType kType> void test_increment_hash(std::string const& bytes, std::string const& result) { - auto hasher = Hasher::Create(type); + auto hasher = Hasher::Create(kType); REQUIRE(hasher.has_value()); hasher->Update(bytes.substr(0, bytes.size() / 2)); hasher->Update(bytes.substr(bytes.size() / 2)); diff --git a/test/buildtool/storage/large_object_cas.test.cpp b/test/buildtool/storage/large_object_cas.test.cpp index b87c8db3..bd8fa98e 100644 --- a/test/buildtool/storage/large_object_cas.test.cpp +++ b/test/buildtool/storage/large_object_cas.test.cpp @@ -42,7 +42,7 @@ namespace { namespace LargeTestUtils { -template <bool IsExecutable> +template <bool kIsExecutable> class Blob final { public: static constexpr auto kLargeId = "bl_8Mb"; @@ -648,24 +648,24 @@ class TestFilesDirectory final { }; namespace LargeTestUtils { -template <bool IsExecutable> -auto Blob<IsExecutable>::Create(LocalCAS<kDefaultDoGlobalUplink> const& cas, - std::string const& id, - std::uintmax_t size) noexcept +template <bool kIsExecutable> +auto Blob<kIsExecutable>::Create(LocalCAS<kDefaultDoGlobalUplink> const& cas, + std::string const& id, + std::uintmax_t size) noexcept -> std::optional<std::pair<ArtifactDigest, std::filesystem::path>> { auto path = Generate(id, size); - auto digest = path ? cas.StoreBlob(*path, IsExecutable) : std::nullopt; + auto digest = path ? cas.StoreBlob(*path, kIsExecutable) : std::nullopt; auto blob_path = - digest ? cas.BlobPath(*digest, IsExecutable) : std::nullopt; + digest ? cas.BlobPath(*digest, kIsExecutable) : std::nullopt; if (digest and blob_path) { return std::make_pair(std::move(*digest), std::move(*blob_path)); } return std::nullopt; } -template <bool IsExecutable> -auto Blob<IsExecutable>::Generate(std::string const& id, - std::uintmax_t size) noexcept +template <bool kIsExecutable> +auto Blob<kIsExecutable>::Generate(std::string const& id, + std::uintmax_t size) noexcept -> std::optional<std::filesystem::path> { std::string const path_id = "blob" + id; auto path = TestFilesDirectory::Instance().GetPath() / path_id; |