From eefba1a2d65a028ab2bd1fd8c85a292e7be7d68d Mon Sep 17 00:00:00 2001 From: zhaona45 Date: Fri, 15 Aug 2025 17:19:16 +0800 Subject: [PATCH] Modify the existing TDD issues Signed-off-by: zhaona45 Change-Id: I759ed1b47e808a055843465f13434a5d5afa56cc --- .../test/unittest/plugin_test/ext_decoder_test.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/frameworks/innerkitsimpl/test/unittest/plugin_test/ext_decoder_test.cpp b/frameworks/innerkitsimpl/test/unittest/plugin_test/ext_decoder_test.cpp index 6e4c1f975..e1b6efba4 100644 --- a/frameworks/innerkitsimpl/test/unittest/plugin_test/ext_decoder_test.cpp +++ b/frameworks/innerkitsimpl/test/unittest/plugin_test/ext_decoder_test.cpp @@ -2166,14 +2166,17 @@ HWTEST_F(ExtDecoderTest, EncodePixelMapTest001, TestSize.Level3) sourceOpts, errorCode); ASSERT_NE(imageSource, nullptr); DecodeOptions opts; - opts.desiredPixelFormat = PixelFormat::YCRCB_P010; + opts.photoDesiredPixelFormat = PixelFormat::YCBCR_P010; + opts.desiredDynamicRange = DecodeDynamicRange::HDR; std::shared_ptr pixelmap = imageSource->CreatePixelMap(opts, errorCode); ASSERT_EQ(errorCode, OHOS::Media::SUCCESS); ASSERT_NE(pixelmap, nullptr); + EXPECT_EQ(pixelmap->GetPixelFormat(), PixelFormat::YCBCR_P010); ImagePacker packer; PackOption option; option.format = "image/heif"; option.needsPackProperties = true; + option.desiredDynamicRange = EncodeDynamicRange::AUTO; uint32_t startpc = packer.StartPacking(IMAGE_DEST, option); ASSERT_EQ(startpc, OHOS::Media::SUCCESS); uint32_t retAddImage = packer.AddImage(*pixelmap); -- Gitee