-
Notifications
You must be signed in to change notification settings - Fork 14
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
#1852 - Enable Overawards Tab For Public Institution User #1906
#1852 - Enable Overawards Tab For Public Institution User #1906
Conversation
sources/packages/backend/apps/api/src/app.institutions.module.ts
Outdated
Show resolved
Hide resolved
sources/packages/backend/apps/api/src/route-controllers/index.ts
Outdated
Show resolved
Hide resolved
...ackages/backend/apps/api/src/route-controllers/overaward/overaward.institution.controller.ts
Outdated
Show resolved
Hide resolved
|
||
it("Should return student overawards", async () => { | ||
// Arrange | ||
const user = await userRepo.save(createFakeUser()); |
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.
is it possible to simplify the "Arrange" area using the saveFakeApplication
?
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.
Unless I am missing something, student and user will also be created by saveFakeApplication
so we would not need the 49 and 50.
...rs/overaward/_tests_/e2e/overaward.institution.controller.getOverawardsByStudent.e2e-spec.ts
Outdated
Show resolved
Hide resolved
...ackages/backend/apps/api/src/route-controllers/overaward/overaward.institution.controller.ts
Outdated
Show resolved
Hide resolved
...ackages/backend/apps/api/src/route-controllers/overaward/overaward.institution.controller.ts
Outdated
Show resolved
Hide resolved
...llers/overaward/_tests_/e2e/overaward.institution.controller.getOverawardBalance.e2e-spec.ts
Outdated
Show resolved
Hide resolved
...rs/overaward/_tests_/e2e/overaward.institution.controller.getOverawardsByStudent.e2e-spec.ts
Outdated
Show resolved
Hide resolved
...rs/overaward/_tests_/e2e/overaward.institution.controller.getOverawardsByStudent.e2e-spec.ts
Outdated
Show resolved
Hide resolved
...llers/overaward/_tests_/e2e/overaward.institution.controller.getOverawardBalance.e2e-spec.ts
Outdated
Show resolved
Hide resolved
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.
Nice job, please take a look at the comments.
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.
Good work @sh16011993 . Added some comments
@@ -22,7 +22,7 @@ | |||
"test:watch": "jest --watch ", | |||
"test:cov": "cross-env ENVIRONMENT=test jest --coverage --forceExit", | |||
"test:debug": "node --inspect-brk -r tsconfig-paths/register -r ts-node/register node_modules/.bin/jest --runInBand", | |||
"test:e2e:api": "npm run db:seed:test filter=CreateInstitutionsAndAuthenticationUsers,CreateAESTUsers,CreateStudentUsers && cross-env ENVIRONMENT=test jest --collect-coverage --verbose --config ./apps/api/test/jest-e2e.json --forceExit", | |||
"test:e2e:api": "npm run db:seed:test filter=CreateInstitutionsAndAuthenticationUsers,CreateAESTUsers,CreateStudentUsers && cross-env NODE_OPTIONS=--max_old_space_size=8192 ENVIRONMENT=test jest --collect-coverage --verbose --config ./apps/api/test/jest-e2e.json --forceExit", |
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.
👍
disbursementOverawardRepo = dataSource.getRepository(DisbursementOveraward); | ||
}); | ||
|
||
it("Should return correct value for overaward balance", async () => { |
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.
We should create the test description with Should/when. e.g.: "Should return correct value for overaward balance when
student has some overawards"
Thanks for making the changes @sh16011993. One last comment on files names. |
…c_institution_user' into 1852_enable_overawards_tab_public_institution_user
...s/overaward/_tests_/e2e/overaward.institutions.controller.getOverawardsByStudent.e2e-spec.ts
Show resolved
Hide resolved
Kudos, SonarCloud Quality Gate passed! 0 Bugs No Coverage information |
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.
Thanks for making the changes @sh16011993 . LGTM.
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.
LGTM!
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.
LGTM, nice work @sh16011993
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.
Good work @sh16011993 👍 Thanks for doing the changes 👍
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.
Thanks for doing the changes, looks good 👍
The following tasks were completed as a part of this task:
Screenshots showing the Overawards tab in the Institution Portal: