-
Notifications
You must be signed in to change notification settings - Fork 12
Brussels | ITP-2025-1 | Preeti Tyagi | Week 6 | Sprint 3 Coursework/sprint-3-practice-tdd #36
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Brussels | ITP-2025-1 | Preeti Tyagi | Week 6 | Sprint 3 Coursework/sprint-3-practice-tdd #36
Conversation
completed the code using for loop
made changes as required
completed the code
completed the code for different cases
made correction
completed the cases
MustafaBora
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Check my comment
| @@ -1,5 +1,11 @@ | |||
| function getOrdinalNumber(num) { | |||
| if (num > 1 || num < 1) { | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you implement this please?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have added implementation in the code. The code is now updated @MustafaBora
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see you have solved the question on get-ordinal-number.test.js.
Test file should contain only the tests, and this file should contain the solution
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tests like:
test("should return '3rd' for 3", () => {
expect(getOrdinalNumber(3)).toEqual("3rd");
});
test("should return '11th' for 11", () => {
expect(getOrdinalNumber(11)).toEqual("11th");
});
test("should return '13th' for 13", () => {
expect(getOrdinalNumber(13)).toEqual("13th");
});
implementation completed.
Self checklist
Change list
Briefly explain your PR.
Questions
Ask any questions you have for your reviewer.