View | Details | Raw Unified | Return to bug 24356
Collapse All | Expand All

(-)a/t/db_dependent/Koha/Object.t (-1 / +24 lines)
Lines 17-23 Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Test::More tests => 18;
20
use Test::More tests => 19;
21
use Test::Exception;
21
use Test::Exception;
22
use Test::Warn;
22
use Test::Warn;
23
use DateTime;
23
use DateTime;
Lines 795-797 subtest 'get_from_storage' => sub { Link Here
795
795
796
    $schema->storage->txn_rollback;
796
    $schema->storage->txn_rollback;
797
};
797
};
798
799
subtest 'prefetch_whitelist() tests' => sub {
800
801
    plan tests => 2;
802
803
    $schema->storage->txn_begin;
804
805
    my $biblio = Koha::Biblio->new;
806
807
    my $prefetch_whitelist = $biblio->prefetch_whitelist;
808
809
    ok(
810
        exists $prefetch_whitelist->{orders},
811
        'Relationship matching method name is listed'
812
    );
813
    is(
814
        $prefetch_whitelist->{orders},
815
        'Koha::Acquisition::Order',
816
        'Guessed the object class correctly'
817
    );
818
819
    $schema->storage->txn_rollback;
820
};
(-)a/t/db_dependent/Koha/Objects.t (-3 / +26 lines)
Lines 19-30 Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Test::More tests => 20;
22
use Test::More tests => 21;
23
use Test::Exception;
23
use Test::Exception;
24
use Test::Warn;
24
use Test::Warn;
25
25
26
use Koha::Authority::Types;
26
use Koha::Authority::Types;
27
use Koha::Cities;
27
use Koha::Cities;
28
use Koha::Biblios;
28
use Koha::Patron::Category;
29
use Koha::Patron::Category;
29
use Koha::Patron::Categories;
30
use Koha::Patron::Categories;
30
use Koha::Patrons;
31
use Koha::Patrons;
Lines 776-779 subtest "from_api_mapping() tests" => sub { Link Here
776
    );
777
    );
777
778
778
    $schema->storage->txn_rollback;
779
    $schema->storage->txn_rollback;
779
};
780
};
781
782
subtest 'prefetch_whitelist() tests' => sub {
783
784
    plan tests => 2;
785
786
    $schema->storage->txn_begin;
787
788
    my $biblios = Koha::Biblios->new;
789
790
    my $prefetch_whitelist = $biblios->prefetch_whitelist;
791
792
    ok(
793
        exists $prefetch_whitelist->{orders},
794
        'Relationship matching method name is listed'
795
    );
796
    is(
797
        $prefetch_whitelist->{orders},
798
        'Koha::Acquisition::Order',
799
        'Guessed the object class correctly'
800
    );
801
802
    $schema->storage->txn_rollback;
803
};
780
- 

Return to bug 24356