Skip to content

Commit 8d02c00

Browse files
test noon midnight and last minutes
1 parent 0aa80bd commit 8d02c00

1 file changed

Lines changed: 12 additions & 0 deletions

File tree

‎format-clock-edge-cases/timeConverter.test.js‎

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,3 +29,15 @@ test("can correctly convert one minute before noon", function () {
2929
test("can correctly convert one hour after noon", function () {
3030
assert.equal(formatAs12HourClock("13:00"), "01:00 pm");
3131
});
32+
33+
test("can correctly convert midnight", function () {
34+
assert.equal(formatAs12HourClock("00:00"), "12:00 am");
35+
});
36+
37+
test("can correctly convert Noon", function () {
38+
assert.equal(formatAs12HourClock("12:00"), "12:00 pm");
39+
});
40+
41+
test("can correctly convert last minutes of the day", function () {
42+
assert.equal(formatAs12HourClock("23:59"), "11:59 pm");
43+
});

0 commit comments

Comments
 (0)