fastify / light-my-request

Fake HTTP injection library
Other
361 stars 47 forks source link

feat: support `FormData` #286

Closed climba03003 closed 5 months ago

climba03003 commented 6 months ago

Support FormData and provide the Content-Type header automatically.

Closes https://github.com/fastify/fastify-multipart/issues/516 Closes https://github.com/fastify/help/issues/1017

Checklist

climba03003 commented 6 months ago

The coverage is really broken in supporting FormData. It can only be used in node >= 18 but we still supporting 14 <= node < 18.

That also force me to ignore the coverage for whole new feature. I have tested, when you remove the ignore in node >= 18, it will works.