Skip to content

Commit 260f20e

Browse files
committed
chore: bumped v4.0.0
Signed-off-by: Matteo Collina <hello@matteocollina.com>
1 parent 815122c commit 260f20e

File tree

4 files changed

+24
-13
lines changed

4 files changed

+24
-13
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ jobs:
55
runs-on: ${{ matrix.os }}
66
strategy:
77
matrix:
8-
node-version: [16.x, 18.x, 20.x]
8+
node-version: [20.x, 22.x]
99
os: [ubuntu-latest]
1010

1111
steps:

package.json

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@mercuriusjs/gateway",
3-
"version": "3.0.1",
3+
"version": "4.0.0",
44
"description": "A plugin for mercurius federation",
55
"main": "index.js",
66
"types": "index.d.ts",
@@ -38,14 +38,14 @@
3838
"devDependencies": {
3939
"@commitlint/cli": "^17.3.0",
4040
"@commitlint/config-conventional": "^17.3.0",
41-
"@fastify/autoload": "^5.6.0",
42-
"@fastify/cors": "^8.2.0",
41+
"@fastify/autoload": "^6.0.0",
42+
"@fastify/cors": "^9.0.0",
4343
"@sinonjs/fake-timers": "^11.0.0",
4444
"@typescript-eslint/eslint-plugin": "^5.44.0",
4545
"@typescript-eslint/parser": "^5.44.0",
4646
"autocannon": "^7.10.0",
4747
"concurrently": "^8.0.1",
48-
"fastify": "^4.16.0",
48+
"fastify": "^5.0.0-alpha.4",
4949
"husky": "^8.0.2",
5050
"lint-staged": "^13.0.4",
5151
"sinon": "^15.0.0",
@@ -62,14 +62,14 @@
6262
"*.{js,jsx}": "standard --cache --fix"
6363
},
6464
"dependencies": {
65-
"@mercuriusjs/federation": "^3.0.0",
66-
"@mercuriusjs/subscription-client": "^1.0.0",
65+
"@mercuriusjs/federation": "^4.0.0",
66+
"@mercuriusjs/subscription-client": "^2.0.0",
6767
"fastify-plugin": "^4.3.0",
6868
"graphql": "^16.6.0",
6969
"graphql-ws": "^5.11.2",
70-
"mercurius": "^14.0.0",
70+
"mercurius": "^15.0.0",
7171
"p-map": "^4.0.0",
72-
"single-user-cache": "^0.6.0",
72+
"single-user-cache": "^1.0.0",
7373
"tiny-lru": "^11.0.0",
7474
"use-strict": "1.0.1",
7575
"ws": "^8.11.0"

test/subscription-hooks.js

Lines changed: 14 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -388,7 +388,9 @@ test('gateway - preSubscriptionParsing hooks should handle errors', async t => {
388388
t.same(data, {
389389
id: 1,
390390
type: 'error',
391-
payload: 'a preSubscriptionParsing error occurred'
391+
payload: [{
392+
message: 'a preSubscriptionParsing error occurred'
393+
}]
392394
})
393395
}
394396
})
@@ -448,7 +450,9 @@ test('gateway - preSubscriptionExecution hooks should handle errors', async t =>
448450
t.same(data, {
449451
id: 1,
450452
type: 'error',
451-
payload: 'a preSubscriptionExecution error occurred'
453+
payload: [{
454+
message: 'a preSubscriptionExecution error occurred'
455+
}]
452456
})
453457
}
454458
})
@@ -503,7 +507,14 @@ test('gateway - preGatewaySubscriptionExecution hooks should handle errors', asy
503507
t.same(data, {
504508
id: 1,
505509
type: 'error',
506-
payload: 'a preGatewaySubscriptionExecution error occurred'
510+
payload: [{
511+
message: 'a preGatewaySubscriptionExecution error occurred',
512+
locations: [{
513+
line: 3,
514+
column: 7
515+
}],
516+
path: ['newMessage']
517+
}]
507518
})
508519
}
509520
})

test/websocket.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ async function createTestService (port, schema, resolvers = {}) {
2020
routes: true,
2121
subscription: true
2222
})
23-
await service.listen(port)
23+
await service.listen({ port })
2424
return service
2525
}
2626

0 commit comments

Comments
 (0)