When native fetch exists, node-fetch and @whatwg-node/fetch polyfills are not used. So in Node 21+, the integration tests for those polyfills are simply testing native fetch.
Therefore, we can skip the integration tests for the node-fetch and @whatwg-node/fetch polyfills when the Node major version is 21 or higher.
The
--no-experimental-fetch
flag was removed in Node 21: https://github.com/nodejs/node/pull/52611When native fetch exists,
node-fetch
and@whatwg-node/fetch
polyfills are not used. So in Node 21+, the integration tests for those polyfills are simply testing native fetch.Therefore, we can skip the integration tests for the
node-fetch
and@whatwg-node/fetch
polyfills when the Node major version is 21 or higher.