aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/decoder/test/endpoint_codec_test.cc1
-rw-r--r--src/decoder/test/image_utils.h2
-rw-r--r--src/decoder/test/intermediate_astc_block_test.cc7
3 files changed, 5 insertions, 5 deletions
diff --git a/src/decoder/test/endpoint_codec_test.cc b/src/decoder/test/endpoint_codec_test.cc
index f2fef54..de7d9ca 100644
--- a/src/decoder/test/endpoint_codec_test.cc
+++ b/src/decoder/test/endpoint_codec_test.cc
@@ -35,7 +35,6 @@ using ::testing::Eq;
using ::testing::Ge;
using ::testing::Le;
using ::testing::Ne;
-using ::testing::Optional;
using ::testing::Pointwise;
using ::testing::SizeIs;
using ::testing::Pair;
diff --git a/src/decoder/test/image_utils.h b/src/decoder/test/image_utils.h
index 718696e..adfded5 100644
--- a/src/decoder/test/image_utils.h
+++ b/src/decoder/test/image_utils.h
@@ -116,7 +116,7 @@ static std::string LoadASTCFile(const std::string& basename) {
}
}
-void LoadGoldenBmp(const std::string& path, ImageBuffer* result) {
+static void LoadGoldenBmp(const std::string& path, ImageBuffer* result) {
constexpr size_t kBmpHeaderSize = 54;
SCOPED_TRACE(testing::Message() << "LoadGoldenBmp " << path);
diff --git a/src/decoder/test/intermediate_astc_block_test.cc b/src/decoder/test/intermediate_astc_block_test.cc
index 69935ef..41861cb 100644
--- a/src/decoder/test/intermediate_astc_block_test.cc
+++ b/src/decoder/test/intermediate_astc_block_test.cc
@@ -27,7 +27,6 @@ namespace {
using ::testing::ElementsAre;
using ::testing::Eq;
using ::testing::HasSubstr;
-using ::testing::Optional;
using ::testing::SizeIs;
using ::testing::TestWithParam;
using ::testing::ValuesIn;
@@ -313,7 +312,8 @@ TEST(IntermediateASTCBlockTest, TestPackingWithLargeGap) {
// if we properly set the endpoint range.
TEST(IntermediateASTCBlockTest, TestEndpointRange) {
PhysicalASTCBlock blk(0x0000000001FE000173ULL);
- EXPECT_THAT(blk.ColorValuesRange(), Optional(Eq(255)));
+ EXPECT_TRUE(blk.ColorValuesRange().hasValue());
+ EXPECT_EQ(blk.ColorValuesRange().valueOr(0), 255);
auto b = UnpackIntermediateBlock(blk);
ASSERT_TRUE(b);
@@ -322,7 +322,8 @@ TEST(IntermediateASTCBlockTest, TestEndpointRange) {
ASSERT_THAT(data.endpoints, SizeIs(1));
EXPECT_THAT(data.endpoints[0].mode, Eq(ColorEndpointMode::kLDRLumaDirect));
EXPECT_THAT(data.endpoints[0].colors, ElementsAre(0, 255));
- EXPECT_THAT(data.endpoint_range, Optional(Eq(255)));
+ EXPECT_TRUE(data.endpoint_range.hasValue());
+ EXPECT_EQ(data.endpoint_range.valueOr(0), 255);
}
struct ImageTestParams {