Skip to content

Commit

Permalink
test: update tests
Browse files Browse the repository at this point in the history
  • Loading branch information
varshamenon4 committed Aug 20, 2024
1 parent cf3156f commit d8bb840
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions src/pages/ExamsPage/components/AllowanceList.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,12 @@ const AllowanceList = () => {
const allowance = {
id,
examId,
userId,
examName,
allowanceType: formatMessage(messages.allowanceTypeMinutes),
extraTimeMins,
username,
email,
};

const user = acc.find(u => u.userId === userId);
Expand Down
2 changes: 1 addition & 1 deletion src/pages/ExamsPage/hooks.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -297,7 +297,7 @@ describe('ExamsPage hooks', () => {
api.createAllowance.mockReturnValue(Promise.resolve({ data: 'data' }));
});
it('calls makeNetworkRequest to edit an allowance', () => {
hooks.useEditAllowance()(formData);
hooks.useEditAllowance()(0, formData);
expect(mockMakeNetworkRequest).toHaveBeenCalledWith({
requestKey: 'createAllowance',
promise: expect.any(Promise),
Expand Down

0 comments on commit d8bb840

Please sign in to comment.