Skip to content

Commit

Permalink
Update dependency sinon to v19 (#172)
Browse files Browse the repository at this point in the history
* Update dependency sinon to v19

* only fake setTimeout

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Jonathan Gray <[email protected]>
  • Loading branch information
renovate[bot] and jonmattgray authored Sep 18, 2024
1 parent 439c140 commit bad952f
Show file tree
Hide file tree
Showing 3 changed files with 67 additions and 49 deletions.
109 changes: 64 additions & 45 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@digicatapult/veritable-cloudagent",
"version": "0.10.20",
"version": "0.10.21",
"main": "build/index",
"type": "module",
"types": "build/index",
Expand Down Expand Up @@ -93,7 +93,7 @@
"mocha": "^10.7.3",
"prettier": "^3.3.3",
"prettier-plugin-organize-imports": "^4.0.0",
"sinon": "^18.0.1",
"sinon": "^19.0.2",
"supertest": "^7.0.0",
"@digicatapult/tsimp": "^2.0.12",
"typescript": "~5.6.2"
Expand Down
3 changes: 1 addition & 2 deletions tests/unit/drpc.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ describe('DrpcController', () => {
})

beforeEach(() => {
clock = useFakeTimers()
clock = useFakeTimers({ toFake: ['setTimeout'] })
})

afterEach(() => {
Expand All @@ -39,7 +39,6 @@ describe('DrpcController', () => {
test("should return undefined if there's no response", async () => {
const spy = stub(agent.modules.drpc, 'sendRequest')
spy.resolves(stub().resolves(undefined))

const response = await request(app).post(`/v1/drpc/${connection.id}/request`).send({
jsonrpc: '2.0',
method: 'test',
Expand Down

0 comments on commit bad952f

Please sign in to comment.