]> git.imager.perl.org - imager.git/blobdiff - t/t90cc.t
prefer static first
[imager.git] / t / t90cc.t
index 50a9158e10845ef73a1d7eab291457efaa049c27..c38453e8128dd77f72bac40e814ae59e10015927 100644 (file)
--- a/t/t90cc.t
+++ b/t/t90cc.t
@@ -1,6 +1,6 @@
 #!perl -w
 use strict;
-use Test::More tests => 16;
+use Test::More tests => 22;
 
 use Imager;
 
@@ -69,3 +69,16 @@ Imager::init('log'=>'testout/t90cc.log');
            $im_g->getcolorusagehash,
            'color usage hash (grey)');
 }
+
+{
+  my $empty = Imager->new;
+  is($empty->getcolorcount, undef, "can't getcolorcount an empty image");
+  is($empty->errstr, "getcolorcount: empty input image",
+     "check error message");
+  is($empty->getcolorusagehash, undef, "can't getcolorusagehash an empty image");
+  is($empty->errstr, "getcolorusagehash: empty input image",
+     "check error message");
+  is($empty->getcolorusage, undef, "can't getcolorusage an empty image");
+  is($empty->errstr, "getcolorusage: empty input image",
+     "check error message");
+}