Open panva opened 8 months ago
In version 1.0.4, I got this error: https://github.com/oven-sh/bun/issues/5006
Now in version 1.1.0, I get this error:
96 | req.path = options.path
^
TypeError: Attempted to assign to readonly property.
at attachToReq (/Users/Julian/Projects//node_modules/nock/lib/intercepted_request_router.js:96:5)
at new InterceptedRequestRouter (/Users/Julian/Projects//node_modules/nock/lib/intercepted_request_router.js:73:5)
at new OverriddenClientRequest (/Users/Julian/Projects//node_modules/nock/lib/intercept.js:290:25)
at /Users/Julian/Projects//node_modules/nock/lib/intercept.js:426:14
at /Users/Julian/Projects//node_modules/nock/lib/common.js:91:14
at /Users/Julian/Projects//node_modules/@smithy/node-http-handler/dist-cjs/index.js:294:19
at new Promise (:1:21)
at /Users/Julian/Projects//node_modules/@smithy/node-http-handler/dist-cjs/index.js:245:12
Probably related: https://github.com/oven-sh/bun/pull/8368
I'm seeing the exact same error as above in v1.1.2.
I just got the same error as well on v1.1.26 😬
What version of Bun is running?
1.0.26+c75e768a6
What platform is your computer?
No response
What steps can reproduce the bug?
What is the expected behavior?
The nock test suite passes, indicating that nock can be used in project test suites to check if they work in bun or not.
What do you see instead?
Additional information
It is impossible for modules that have existing test suite for the Node.js runtime to test and assert their module works in Bun if the test suite doesn't even run in Bun.
nock
is a very common library for mocking http responses for thenode:http
andnode:https
modules.