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

(-)a/t/db_dependent/Koha/Biblio.t (-2 / +22 lines)
Lines 1168-1174 subtest 'get_marc_notes() UNIMARC tests' => sub { Link Here
1168
};
1168
};
1169
1169
1170
subtest 'host_items() tests' => sub {
1170
subtest 'host_items() tests' => sub {
1171
    plan tests => 7;
1171
    plan tests => 8;
1172
1172
1173
    $schema->storage->txn_begin;
1173
    $schema->storage->txn_begin;
1174
1174
Lines 1199-1204 subtest 'host_items() tests' => sub { Link Here
1199
    is_deeply( [ $host_items->get_column('itemnumber') ],
1199
    is_deeply( [ $host_items->get_column('itemnumber') ],
1200
        [ $host_item_1->itemnumber, $host_item_2->itemnumber ] );
1200
        [ $host_item_1->itemnumber, $host_item_2->itemnumber ] );
1201
1201
1202
    my $transfer = $builder->build_object(
1203
        {
1204
            class => 'Koha::Item::Transfers',
1205
            value => {
1206
                itemnumber => $host_item_1->itemnumber,
1207
                frombranch => $host_item_1->holdingbranch,
1208
            }
1209
        }
1210
    );
1211
    ok(
1212
        $host_items->search(
1213
            {},
1214
            {
1215
                join     => 'branchtransfers',
1216
                order_by => 'branchtransfers.daterequested'
1217
            }
1218
        )->as_list,
1219
        "host_items can be used with a join query on itemnumber"
1220
    );
1221
    $transfer->delete;
1222
1202
    t::lib::Mocks::mock_preference( 'EasyAnalyticalRecords', 0 );
1223
    t::lib::Mocks::mock_preference( 'EasyAnalyticalRecords', 0 );
1203
    $host_items = $biblio->host_items;
1224
    $host_items = $biblio->host_items;
1204
    is( ref($host_items),   'Koha::Items' );
1225
    is( ref($host_items),   'Koha::Items' );
1205
- 

Return to bug 36317