Skip to content

Commit 87f874b

Browse files
Implement th suffix
1 parent e0a7c74 commit 87f874b

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

‎practice-tdd/get-ordinal-number.test.js‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,3 +30,9 @@ test("should append 'rd' for numbers ending with 3, except those ending with 13"
3030
expect(getOrdinalNumber(23)).toEqual("23rd");
3131
expect(getOrdinalNumber(113)).toEqual("113th");
3232
});
33+
34+
test("should append 'th' for other numbers", () => {
35+
expect(getOrdinalNumber(4)).toEqual("4th");
36+
expect(getOrdinalNumber(24)).toEqual("24th");
37+
expect(getOrdinalNumber(114)).toEqual("114th");
38+
});

0 commit comments

Comments
 (0)