-
Notifications
You must be signed in to change notification settings - Fork 41
Build test #41
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?
Build test #41
Conversation
gemtechd
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.
- You have to make changes in the code itself (checks for parameters), that the code will be good code
- remove all comments before pushing
package.json
Outdated
| "dependencies": { | ||
| "jest": "^29.7.0" | ||
| "jest": "^29.7.0", | ||
| "coverage":"npm run test -- --coverage" |
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.
This is not the correct place for these modules
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.
this problem is still not fixed
and don't write scripts inside dependencies
| const line = new Line({ point1, point2 }); | ||
| line.calculateSlope(); | ||
| line.calculateNOfLineFunction(); | ||
| const pointOnXAxis = line.getPointOnXAsis(); |
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.
You don't use different functions in the tests to assure that you test won't fail
You have to change the code itself
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.
this problem is still not fixed
| const line = new Line({ point1, point2 }); | ||
| line.calculateSlope(); | ||
| line.calculateNOfLineFunction(); | ||
| const pointOnYAxis = line.getPointOnYAsis(); |
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.
You don't use different functions in the tests to assure that you test won't fail
You have to change the code itself
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.
this problem is still not fixed
| const line = new Line({ point1, point2 }); | ||
| line.calculateSlope(); | ||
| line.calculateNOfLineFunction(); | ||
| const targetX = 4; |
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.
You don't use different functions in the tests to assure that you test won't fail
You have to change the code itself
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.
These file will be tested after you'll make some changes in the code
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.
this problem is still not fixed
gemtechd
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.
Work on all comments
good luck
| const line = new Line({ point1, point2 }); | ||
| line.calculateSlope(); | ||
| line.calculateNOfLineFunction(); | ||
|
|
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.
it the tests, you test only one function.
Why do you call the calculateSlope here?
| const line = new Line({ point1, point2 }); | ||
| line.calculateSlope(); | ||
| line.calculateNOfLineFunction(); | ||
| const pointOnYAxis = line.getPointOnYAsis(); |
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.
this problem is still not fixed
| const line = new Line({ point1, point2 }); | ||
| line.calculateSlope(); | ||
| line.calculateNOfLineFunction(); | ||
| const pointOnXAxis = line.getPointOnXAsis(); |
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.
this problem is still not fixed
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.
this problem is still not fixed
package.json
Outdated
| "dependencies": { | ||
| "jest": "^29.7.0" | ||
| "jest": "^29.7.0", | ||
| "coverage":"npm run test -- --coverage" |
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.
this problem is still not fixed
and don't write scripts inside dependencies
|
I push the changes |
The purpose of this project is to practice unit tests in javascript. You have to write tests to all modules in the modules folder. You'll have to add code to some functions.