Bug 6758: Use 'is' instead of 'ok' in tests
authorJonathan Druart <jonathan.druart@bugs.koha-community.org>
Tue, 19 Sep 2017 16:13:47 +0000 (13:13 -0300)
committerJonathan Druart <jonathan.druart@bugs.koha-community.org>
Tue, 19 Sep 2017 17:15:16 +0000 (14:15 -0300)
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
t/db_dependent/Koha/Patrons.t

index d1c81fc..a0a19fd 100644 (file)
@@ -307,7 +307,7 @@ subtest 'renew_account' => sub {
         $expiry_date = $retrieved_patron->renew_account;
         is( $expiry_date, $a_year_later, "today + 12 months must be $a_year_later" );
         $retrieved_patron = Koha::Patrons->find( $patron->{borrowernumber} );
-        ok( $retrieved_patron->date_renewed, "Date renewed is set when calling renew_account" );
+        is( $retrieved_patron->date_renewed, output_pref({ dt => $dt, dateformat => 'iso', dateonly => 1 }), "Date renewed is set when calling renew_account" );
         $retrieved_expiry_date = $retrieved_patron->dateexpiry;
         is( dt_from_string($retrieved_expiry_date), $a_year_later, "today + 12 months must be $a_year_later" );
         $number_of_logs = $schema->resultset('ActionLog')->search( { module => 'MEMBERS', action => 'RENEW', object => $retrieved_patron->borrowernumber } )->count;