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

(-)a/t/db_dependent/Koha/Database/DataInconsistency.t (-2 / +30 lines)
Lines 1-7 Link Here
1
use Modern::Perl;
1
use Modern::Perl;
2
2
3
use Test::NoWarnings;
3
use Test::NoWarnings;
4
use Test::More tests => 7;
4
use Test::More tests => 8;
5
use Test::Warn;
5
use Test::Warn;
6
6
7
use Koha::Items;
7
use Koha::Items;
Lines 436-438 subtest 'empty_title' => sub { Link Here
436
        );
436
        );
437
    };
437
    };
438
};
438
};
439
- 
439
440
subtest 'for_biblio' => sub {
441
442
    plan tests => 1;
443
444
    $schema->storage->txn_begin();
445
446
    my $biblio_ok = $builder->build_sample_biblio;
447
    my $item_ok   = $builder->build_sample_item( { biblionumber => $biblio_ok->biblionumber } );
448
449
    subtest 'ok' => sub {
450
        plan tests => 1;
451
        my $errors = Koha::Database::DataInconsistency->for_biblio($biblio_ok);
452
        is_deeply(
453
            $errors,
454
            {
455
                decoding_errors      => [],
456
                empty_title          => [],
457
                ids_not_in_marc      => [],
458
                invalid_item_library => [],
459
                invalid_item_type    => [],
460
                item_fields_in_marc  => [],
461
                no_item_type         => [],
462
                nonexistent_AV       => []
463
            }
464
        );
465
    };
466
467
};

Return to bug 40777