Upgrade to Compress::Zlib 2.000_05
[p5sagit/p5-mst-13.2.git] / ext / Compress / Zlib / t / 01version.t
1
2 use lib 't';
3 use strict ;
4 use warnings ;
5
6 use Test::More ;
7
8 BEGIN 
9
10     # use Test::NoWarnings, if available
11     my $extra = 0 ;
12     $extra = 1
13         if eval { require Test::NoWarnings ;  import Test::NoWarnings; 1 };
14
15     plan tests => 2 + $extra ;
16
17     use_ok('Compress::Zlib', 2) ; 
18 }
19
20 # Check zlib_version and ZLIB_VERSION are the same.
21
22 my $zlib_h = ZLIB_VERSION ;
23 my $libz   = Compress::Zlib::zlib_version;
24
25 is($zlib_h, $libz, "ZLIB_VERSION ($zlib_h) matches Compress::Zlib::zlib_version")
26     or diag <<EOM;
27
28 The version of zlib.h does not match the version of libz
29  
30 You have zlib.h version $zlib_h
31      and libz   version $libz
32  
33 You probably have two versions of zlib installed on your system.
34 Try removing the one you don't want to use and rebuild.
35 EOM
36