Fixed browser unit test.
This commit is contained in:
parent
96d300b912
commit
3c788ca426
1 changed files with 4 additions and 4 deletions
|
@ -346,11 +346,11 @@ test("check pretty date", function() {
|
||||||
// for less than 6 days
|
// for less than 6 days
|
||||||
// weekday HH::MM
|
// weekday HH::MM
|
||||||
if (diff < (60 * 60 * 24 * 6))
|
if (diff < (60 * 60 * 24 * 6))
|
||||||
string = weekday + ' ' + date.getHours() + ':' + (date.getMinutes() < 10 ? '0':'') + date.getMinutes()
|
string = weekday + ' ' + H + ':' + (M < 10 ? '0':'') + M
|
||||||
else if (current.getYear() == date.getYear())
|
else if (current.getYear() == date.getYear())
|
||||||
string = weekday + ' ' + date.getDate() + '. ' + month + ' ' + H + ":" + (M < 10 ? '0':'') + M
|
string = weekday + ' ' + date.getDate() + '. ' + month + ' ' + H + ':' + (M < 10 ? '0':'') + M
|
||||||
else
|
else
|
||||||
string = weekday + ' ' + (m < 10 ? '0':'') + m + '/' + (d < 10 ? '0':'') + d + '/' + (yfull) + ' ' + H + ":" + (M < 10 ? '0':'') + M
|
string = weekday + ' ' + (m < 10 ? '0':'') + m + '/' + (d < 10 ? '0':'') + d + '/' + (yfull) + ' ' + (H < 10 ? '0':'') + H + ':' + (M < 10 ? '0':'') + M
|
||||||
return string;
|
return string;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -364,7 +364,7 @@ test("check pretty date", function() {
|
||||||
H = date.getHours()
|
H = date.getHours()
|
||||||
|
|
||||||
// YYYY-MM-DD HH::MM
|
// YYYY-MM-DD HH::MM
|
||||||
return (m < 10 ? '0':'') + m + '/' + (d < 10 ? '0':'') + d + '/' + (yfull) + ' ' + (H < 10 ? '0':'') + H + ":" + (M < 10 ? '0':'') + M
|
return (m < 10 ? '0':'') + m + '/' + (d < 10 ? '0':'') + d + '/' + (yfull) + ' ' + (H < 10 ? '0':'') + H + ':' + (M < 10 ? '0':'') + M
|
||||||
}
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in a new issue