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

(-)a/t/db_dependent/Virtualshelves.t (-2 / +8 lines)
Lines 19-25 $dbh->{AutoCommit} = 0; Link Here
19
teardown();
19
teardown();
20
20
21
subtest 'CRUD' => sub {
21
subtest 'CRUD' => sub {
22
    plan tests => 12;
22
    plan tests => 13;
23
    my $patron = $builder->build({
23
    my $patron = $builder->build({
24
        source => 'Borrower',
24
        source => 'Borrower',
25
    });
25
    });
Lines 43-48 subtest 'CRUD' => sub { Link Here
43
    is( $shelf->allow_change_from_others, 0, 'The default value for allow_change_from_others should be 0' );
43
    is( $shelf->allow_change_from_others, 0, 'The default value for allow_change_from_others should be 0' );
44
    is( output_pref($shelf->created_on), output_pref(dt_from_string), 'The creation time should have been set to today' );
44
    is( output_pref($shelf->created_on), output_pref(dt_from_string), 'The creation time should have been set to today' );
45
45
46
    my $shelf_18672 = Koha::Virtualshelves->find( $shelf->shelfnumber ); # Bug 18672
47
    my $created_18672 = $shelf_18672->created_on;
48
    sleep 2; # Wait 2 seconds, then store
49
    $shelf->store;
50
    $shelf_18672 = Koha::Virtualshelves->find( $shelf->shelfnumber );
51
    is($shelf_18672->created_on, $created_18672, 'Creation date is the same after update (Bug 18672)' );
52
46
    my $retrieved_shelf = Koha::Virtualshelves->find( $shelf->shelfnumber );
53
    my $retrieved_shelf = Koha::Virtualshelves->find( $shelf->shelfnumber );
47
54
48
    is( $retrieved_shelf->shelfname, $shelf->shelfname, 'Find should correctly return the shelfname' );
55
    is( $retrieved_shelf->shelfname, $shelf->shelfname, 'Find should correctly return the shelfname' );
49
- 

Return to bug 18672