Skip to content

Commit

Permalink
[libpng16] test: Move cicp-display-p3_reencoded.png to contrib/testpn…
Browse files Browse the repository at this point in the history
…gs/png-3/

Update the main CMake file and the auxiliary test scripts accordingly.

This is a cherry-pick of commit fe277b7
from branch 'libpng18'.
  • Loading branch information
ctruta committed Jan 2, 2025
1 parent 823c2d8 commit 4599354
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2 deletions.
6 changes: 4 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -804,6 +804,8 @@ if(PNG_TESTS AND PNG_SHARED)
list(SORT PNGSUITE_PNGS)
file(GLOB TEST_PNGS "${CMAKE_CURRENT_SOURCE_DIR}/contrib/testpngs/*.png")
list(SORT TEST_PNGS)
file(GLOB TEST_PNG3_PNGS "${CMAKE_CURRENT_SOURCE_DIR}/contrib/testpngs/png-3/*.png")
list(SORT TEST_PNG3_PNGS)

set(PNGTEST_PNG "${CMAKE_CURRENT_SOURCE_DIR}/pngtest.png")

Expand All @@ -814,9 +816,9 @@ if(PNG_TESTS AND PNG_SHARED)
COMMAND pngtest
FILES "${PNGTEST_PNG}")

png_add_test(NAME pngtest-cicp
png_add_test(NAME pngtest-png-3
COMMAND pngtest
FILES "${CMAKE_CURRENT_SOURCE_DIR}/cicp-display-p3_reencoded.png")
FILES "${TEST_PNG3_PNGS}")

add_executable(pngvalid ${pngvalid_sources})
target_link_libraries(pngvalid PRIVATE png_shared)
Expand Down
File renamed without changes
3 changes: 3 additions & 0 deletions tests/pngtest-all
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ TEST(){
# The "standard" test
TEST --strict "${srcdir}"/pngtest.png

# PNG-3 tests
TEST --strict "${srcdir}"/contrib/testpngs/png-3/*.png

# Various crashers
# Use --relaxed because some come from fuzzers that don't maintain CRCs
TEST --relaxed "${srcdir}"/contrib/testpngs/crashers/badcrc.png
Expand Down

0 comments on commit 4599354

Please # to comment.