diff options
author | Zach van Rijn <me@zv.io> | 2022-04-19 12:35:20 -0500 |
---|---|---|
committer | A. Wilcox <AWilcox@Wilcox-Tech.com> | 2022-05-01 17:05:56 -0500 |
commit | e03bbd44e45aa58a8979703000b99228d45717d5 (patch) | |
tree | 76ac1ec39fc60e80e8449e11d5666fca0d962fd3 /system/perl/zlib-test.patch | |
parent | 35890573a59b72293977841f74ef998c8d77bd20 (diff) | |
download | packages-e03bbd44e45aa58a8979703000b99228d45717d5.tar.gz packages-e03bbd44e45aa58a8979703000b99228d45717d5.tar.bz2 packages-e03bbd44e45aa58a8979703000b99228d45717d5.tar.xz packages-e03bbd44e45aa58a8979703000b99228d45717d5.zip |
system/perl: bump { 5.34.0 --> 5.34.1 }. patch zlib tests. fixes #530.
Diffstat (limited to 'system/perl/zlib-test.patch')
-rw-r--r-- | system/perl/zlib-test.patch | 80 |
1 files changed, 80 insertions, 0 deletions
diff --git a/system/perl/zlib-test.patch b/system/perl/zlib-test.patch new file mode 100644 index 000000000..1cb8f5e80 --- /dev/null +++ b/system/perl/zlib-test.patch @@ -0,0 +1,80 @@ +diff --git a/cpan/Compress-Raw-Zlib/t/02zlib.t b/cpan/Compress-Raw-Zlib/t/02zlib.t +index 64c8944..9b2e9cb 100644 +--- a/cpan/Compress-Raw-Zlib/t/02zlib.t ++++ b/cpan/Compress-Raw-Zlib/t/02zlib.t +@@ -13,6 +13,7 @@ use bytes; + use Test::More ; + use CompTestUtils; + ++use constant ZLIB_1_2_12_0 => 0x12C0; + + BEGIN + { +@@ -490,7 +491,16 @@ SKIP: + last if $status == Z_STREAM_END or $status != Z_OK ; + } + +- cmp_ok $status, '==', Z_DATA_ERROR ; ++ # Z_STREAM_END returned by 1.12.2, Z_DATA_ERROR for older zlib ++ if (ZLIB_VERNUM >= ZLIB_1_2_12_0) ++ { ++ cmp_ok $status, '==', Z_STREAM_END ; ++ } ++ else ++ { ++ cmp_ok $status, '==', Z_DATA_ERROR ; ++ } ++ + is $GOT, $goodbye ; + + +@@ -514,7 +524,17 @@ SKIP: + is length($rest), $len2, "expected compressed output"; + + $GOT = ''; +- cmp_ok $k->inflate($rest, $GOT), '==', Z_DATA_ERROR, "inflate returns Z_DATA_ERROR"; ++ $status = $k->inflate($rest, $GOT); ++ # Z_STREAM_END returned by 1.12.2, Z_DATA_ERROR for older zlib ++ if (ZLIB_VERNUM >= ZLIB_1_2_12_0) ++ { ++ cmp_ok $status, '==', Z_STREAM_END ; ++ } ++ else ++ { ++ cmp_ok $status, '==', Z_DATA_ERROR ; ++ } ++ + is $GOT, $goodbye ; + } + +diff --git a/cpan/IO-Compress/t/cz-03zlib-v1.t b/cpan/IO-Compress/t/cz-03zlib-v1.t +index 9b75f9b..41734d0 100644 +--- a/cpan/IO-Compress/t/cz-03zlib-v1.t ++++ b/cpan/IO-Compress/t/cz-03zlib-v1.t +@@ -14,6 +14,8 @@ use Test::More ; + use CompTestUtils; + use Symbol; + ++use constant ZLIB_1_2_12_0 => 0x12C0; ++ + BEGIN + { + # use Test::NoWarnings, if available +@@ -700,7 +702,16 @@ EOM + + ($GOT, $status) = $k->inflate($rest) ; + +- ok $status == Z_DATA_ERROR ; ++ # Z_STREAM_END returned by 1.12.2, Z_DATA_ERROR for older zlib ++ if (ZLIB_VERNUM >= ZLIB_1_2_12_0) ++ { ++ cmp_ok $status, '==', Z_STREAM_END ; ++ } ++ else ++ { ++ cmp_ok $status, '==', Z_DATA_ERROR ; ++ } ++ + ok $Z . $GOT eq $goodbye ; + } + |