5 use Test
::More tests
=> 126;
6 use File
::Slurper qw
/read_binary/;
8 use IO
::Uncompress
::Brotli
;
10 for my $test (<brotli
/tests/testdata
/*.compressed
*>) {
11 my ($expected) = $test =~ s/\.compressed.*//r;
12 $expected = read_binary
$expected;
14 my $decoded = unbro
((scalar read_binary
$test), 1_000_000
);
15 is
$decoded, $expected, "$test (two-argument unbro)";
17 $decoded = unbro
scalar read_binary
$test;
18 is
$decoded, $expected, "$test (one-argument unbro)";
22 my $unbro = IO
::Uncompress
::Brotli
->create;
26 $out .= $unbro->decompress($buf);
28 is
$out, $expected, "$test (streaming)";
This page took 0.02319 seconds and 4 git commands to generate.