3 # Copyright (C) 2003 Tels
4 # Copyright (C) 2004 David J. Goehrig
6 # basic testing of SDL::Color
9 unshift @INC, 'blib/lib','blib/arch';
18 use_ok( 'SDL::Color' );
20 can_ok ('SDL::Color', qw/
29 my $color = SDL::Color->new();
30 is (ref($color), 'SDL::Color', 'new was ok');
31 is ($color->r(),0, 'r is 0');
32 is ($color->g(),0, 'g is 0');
33 is ($color->b(),0, 'b is 0');
35 $color = SDL::Color->new( -r => 0xff, -g => 0xff, -b => 0xff);
36 is (ref($color), 'SDL::Color', 'new was ok');
37 is ($color->r(),255, 'r is 255');
38 is ($color->g(),255, 'g is 255');
39 is ($color->b(),255, 'b is 255');