-
Notifications
You must be signed in to change notification settings - Fork 29
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: Simplify supertest-koa bootstrap #163
Conversation
🦋 Changeset is good to goLatest commit: 72f5d31 We got this. Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Well isn't that simple, thanks 🤦
|
||
return Object.assign(getAgent, { setup, teardown }); | ||
const agent: request.SuperTest<request.Test> = request.agent(app.callback()); | ||
return () => agent; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wonder if we should just return agent
directly from all these helpers? That way we can just do agent.do()
rather than agent().do()
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
0e47685
to
9288fd5
Compare
Don't start the server and avoid the need to stop it.