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

(-)a/t/db_dependent/Context.t (-5 / +3 lines)
Lines 150-159 sub get_current_time { Link Here
150
    $sth->execute();
150
    $sth->execute();
151
    return $sth->fetchrow_array;# Return a time value rather than hash value
151
    return $sth->fetchrow_array;# Return a time value rather than hash value
152
}
152
}
153
my $datetime = DateTime->now;
153
154
my $date = $datetime->ymd;
154
my ($second,$min,$hour,$mday,$month,$year,$weekday,$yday,$isdst) = localtime(time);
155
my $time = $datetime->hms;
155
my $compardt = sprintf("%04d-%02d-%02d %02d:%02d:%02d", $year+1900, $month+1, $mday, $hour, $min, $second);
156
my $compardt = "$date $time";
157
156
158
my $current_time = get_current_time();
157
my $current_time = get_current_time();
159
is($current_time, $compardt, "Correct time");
158
is($current_time, $compardt, "Correct time");
160
- 

Return to bug 18299