| 1 |
use Test2::Bundle::Extended -target => 'Test2::Compare::Wildcard'; |
| 2 |
|
| 3 |
my $one = $CLASS->new(expect => 'foo'); |
| 4 |
isa_ok($one, $CLASS, 'Test2::Compare::Base'); |
| 5 |
|
| 6 |
ok(defined $CLASS->new(expect => 0), "0 is a valid expect value"); |
| 7 |
ok(defined $CLASS->new(expect => undef), "undef is a valid expect value"); |
| 8 |
ok(defined $CLASS->new(expect => ''), "'' is a valid expect value"); |
| 9 |
|
| 10 |
like( |
| 11 |
dies { $CLASS->new() }, |
| 12 |
qr/'expect' is a require attribute/, |
| 13 |
"Need to specify 'expect'" |
| 14 |
); |
| 15 |
|
| 16 |
done_testing; |