- some sub-directory tests depended on files produced by the parent
[imager.git] / dynfilt / t / t60dyntest.t
1 #!perl -w
2 use strict;
3 use lib '../t';
4 use Test::More tests => 4;
5 BEGIN { use_ok(Imager => qw(:default)); }
6 use Config;
7
8 #$Imager::DEBUG=1;
9
10 Imager::init('log'=>'../testout/t60dyntest.log');
11
12 my $img=Imager->new() || die "unable to create image object\n";
13
14 $img->read(file=>'../testimg/penguin-base.ppm',type=>'pnm') 
15   || die "failed: ",$img->{ERRSTR},"\n";
16
17 my $plug='./dyntest.'.$Config{'so'};
18 ok(load_plugin($plug), "load plugin")
19   || die "unable to load plugin: $Imager::ERRSTR\n";
20
21 my %hsh=(a=>35,b=>200,type=>'lin_stretch');
22 ok($img->filter(%hsh), "call filter");
23
24 $img->write(type=>'pnm',file=>'../testout/t60.ppm') 
25   || die "error in write()\n";
26
27 ok(unload_plugin($plug), "unload plugin")
28   || die "unable to unload plugin: $Imager::ERRSTR\n";
29
30
31