Open joshuaavalon opened 1 year ago
Thanks for reporting!
Can you provide steps to reproduce? We often need a reproducible example, e.g. some code that allows someone else to recreate your problem by just copying and pasting it. If it involves more than a couple of different file, create a new repository on GitHub and add a link to that.
Example: https://github.com/joshuaavalon/fastify-nextjs-bug
npm i
npm run start
Expect the script to stop after 1
is print, however, it does not stop.
The expected behavior is what commenting out await app.register(nextPlugin);
in index.js
.
Apparently we have not tests using inject()
, so it's likely possible this would never work or it would not be possible to make it work.
https://github.com/fastify/fastify-nextjs/blob/master/test/index.test.js
My current workaround is just to not register this plugin when using inject
.
Prerequisites
Fastify version
4.17.0
Plugin version
9.2.0
Node.js version
v20.1.0
Operating system
Windows
Operating system version (i.e. 20.04, 11.3, 10)
10
Description
When I run unit tests by
fastify.inject
, it timeout after several requests.Steps to Reproduce
I run test with the following
Expected Behavior
The tests do not timeout