-
Notifications
You must be signed in to change notification settings - Fork 4
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
feat: add e2e tests #135
feat: add e2e tests #135
Conversation
fix: Change the export type of 'Course'
backend/src/app.module.ts
Outdated
AuthModule, | ||
// AuthModule, |
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.
Don't do this.
course.departmentId = 'csie'; | ||
await this.courseRepository.save(course); | ||
|
||
for (let i = 0; i < 200; i++) { |
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.
Do you need so much fake data?
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.
Because I need to test changing the courses pages.
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.
Would the test pass if we only have 100 courses? You should consider the minimal test data.
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 can help that
) {} | ||
|
||
async seedCourse() { | ||
await this.courseRepository.clear(); |
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.
Could you extract it into the npm script?
Co-authored-by: ppodds <oscar20020629@gmail.com>
No description provided.