Lines 494-501
subtest 'build_object() tests' => sub {
Link Here
|
494 |
my $object = $builder->build_object( { class => $module } ); |
494 |
my $object = $builder->build_object( { class => $module } ); |
495 |
is( ref($object), $module->object_class, "Testing $module" ); |
495 |
is( ref($object), $module->object_class, "Testing $module" ); |
496 |
|
496 |
|
|
|
497 |
if ( $module ne 'Koha::File::Transports' ) { # Skip polymorphic classes |
498 |
is( ref($object), $module->object_class, "Testing $module" ); |
499 |
} |
500 |
|
497 |
if ( !grep { $module eq $_ } qw( Koha::Old::Patrons Koha::Statistics ) ) |
501 |
if ( !grep { $module eq $_ } qw( Koha::Old::Patrons Koha::Statistics ) ) |
498 |
{ # FIXME deletedborrowers and statistics do not have a PK |
502 |
{ # FIXME deletedborrowers and statistics do not have a PK |
499 |
eval { $object->get_from_storage }; |
503 |
eval { $object->get_from_storage }; |
500 |
is( $@, '', "Module $module should have koha_object[s]_class method if needed" ); |
504 |
is( $@, '', "Module $module should have koha_object[s]_class method if needed" ); |
501 |
} |
505 |
} |
502 |
- |
|
|