Skip to content

Commit

Permalink
fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
marcuspoehls committed Aug 22, 2023
1 parent 8e89b30 commit f579f21
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions packages/session/test/session-manager.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@ test.group('Session Manager', () => {
const server = app.make(Server)
const sessionManager = new SessionManager(app)

server.use(({ request, response }) => {
const session = sessionManager.createFrom(request)
server.use(ctx => {
const session = sessionManager.createFrom(ctx)

return response.payload(session.id())
return ctx.response.payload(session.id())
})

const response = await Supertest(server.callback())
Expand Down Expand Up @@ -44,11 +44,11 @@ test.group('Session Manager', () => {

server
.use(StartSessionMiddleware)
.use(({ request, response }) => {
const session = sessionManager.createFrom(request)
.use(ctx => {
const session = sessionManager.createFrom(ctx)
session.set('foo', 'bar')

return response.payload(session.id())
return ctx.response.payload(session.id())
})

const response = await Supertest(server.callback())
Expand All @@ -74,11 +74,11 @@ test.group('Session Manager', () => {

server
.use(StartSessionMiddleware)
.use(({ request, response }) => {
const session = sessionManager.createFrom(request)
.use(ctx => {
const session = sessionManager.createFrom(ctx)
session.set('foo', 'bar')

return response.payload(session.id())
return ctx.response.payload(session.id())
})

const response = await Supertest(server.callback())
Expand Down

0 comments on commit f579f21

Please sign in to comment.