Skip to content

Commit

Permalink
resolve pr requests
Browse files Browse the repository at this point in the history
  • Loading branch information
greg-adams committed Aug 29, 2024
1 parent 35815f5 commit 98c7424
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 10 deletions.
3 changes: 0 additions & 3 deletions api/setup-jest.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
import initializeDb from './src/lib/db'

beforeAll(async () => {
// avoid conflict in dev container
process.env.NODE_ENV = 'test';

await initializeDb()
})
11 changes: 4 additions & 7 deletions api/src/services/users/users.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -284,8 +284,8 @@ describe('user writes', () => {
})

expect(result.passageId).toEqual('new-id-1')
expect(mockPassageUser.create).to.haveBeenCalled()
expect(mockPassageUser.activate).to.haveBeenCalled()
expect(mockPassageUser.create).toHaveBeenCalled()
expect(mockPassageUser.activate).toHaveBeenCalled()
})

scenario(
Expand Down Expand Up @@ -353,11 +353,8 @@ describe('user writes', () => {
email: scenario.user.one.email,
roles: ['USDR_ADMIN'],
})
await deleteUser({
id: scenario.user.one.id,
}))
expect(mockPassageUser.delete).toHaveBeenCalledWith(scenario.user.one.passageId)

await deleteUser({ id: scenario.user.one.id })
expect(mockPassageUser.delete).toHaveBeenCalledWith(scenario.user.one.passageId)

Check warning on line 357 in api/src/services/users/users.test.ts

View workflow job for this annotation

GitHub Actions / qa / Lint JavaScript

Replace `scenario.user.one.passageId` with `⏎········scenario.user.one.passageId⏎······`
})
})
})
Expand Down

0 comments on commit 98c7424

Please sign in to comment.