Bug 10380: (follow-up) remove inadvertant database dependency for t/DateUtils.t

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
This commit is contained in:
Galen Charlton 2013-10-18 04:27:42 +00:00
parent 8a6793af02
commit 66de7d0e17
1 changed files with 9 additions and 0 deletions

View File

@ -6,6 +6,7 @@ use DateTime::TimeZone;
use C4::Context;
use Test::More tests => 31;
use Test::MockModule;
BEGIN { use_ok('Koha::DateUtils'); }
@ -25,6 +26,14 @@ $dt->set_minute(0);
my $date_string;
my $module_context = new Test::MockModule('C4::Context');
$module_context->mock(
'preference',
sub {
return 'us';
}
);
my $dateformat = C4::Context->preference('dateformat');
cmp_ok output_pref({ dt => $dt, dateformat => $dateformat }),
'eq',