fastify-typescript-generator icon indicating copy to clipboard operation
fastify-typescript-generator copied to clipboard

server not exposed in tests for projects generated with mongoose template

Open laurentmor opened this issue 4 years ago • 0 comments

tools used NPM 7.5.4 Node 16.9.1 Typescript 4.2.4 fastify-gen 0.3.0 Jest 26.6.3 Issue description
Using the generated code out of the box during test execution, we encounter the following error: image I suspect that the following snippet is causing this: image Server startup code is as follow: image

Despite the fastify server object being returned by the exported init() method, it looks like fastify server instance and methods are not exposed to test

** Expected behavior** Tests should work out of the box just fine

Am I doing something wrong ?

laurentmor avatar Sep 18 '21 16:09 laurentmor