mirror of
https://github.com/nodejs/node.git
synced 2024-11-30 15:30:56 +01:00
e038d6a1cd
This completely refactors the `expectsError` behavior: so far it's almost identical to `assert.throws(fn, object)` in case it was used with a function as first argument. It had a magical property check that allowed to verify a functions `type` in case `type` was passed used in the validation object. This pattern is now completely removed and `assert.throws()` should be used instead. The main intent for `common.expectsError()` is to verify error cases for callback based APIs. This is now more flexible by accepting all validation possibilites that `assert.throws()` accepts as well. No magical properties exist anymore. This reduces surprising behavior for developers who are not used to the Node.js core code base. This has the side effect that `common` is used significantly less frequent. PR-URL: https://github.com/nodejs/node/pull/31092 Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com> |
||
---|---|---|
.. | ||
test-dgram-broadcast-multi-process.js | ||
test-dgram-connect.js | ||
test-dgram-membership.js | ||
test-dgram-multicast-multi-process.js | ||
test-dgram-multicast-set-interface-lo.js | ||
test-dgram-multicast-ssm-multi-process.js | ||
test-dgram-multicast-ssmv6-multi-process.js | ||
test-dns-any.js | ||
test-dns-cares-domains.js | ||
test-dns-idna2008.js | ||
test-dns-ipv4.js | ||
test-dns-ipv6.js | ||
test-dns-lookup.js | ||
test-dns-promises-resolve.js | ||
test-dns-regress-6244.js | ||
test-dns-setserver-in-callback-of-resolve4.js | ||
test-dns-txt-sigsegv.js | ||
test-dns.js | ||
test-http-dns-fail.js | ||
test-http-https-default-ports.js | ||
test-inspector-help-page.js | ||
test-net-connect-timeout.js | ||
test-net-connect-unref.js | ||
test-tls-add-ca-cert.js | ||
test-tls-connnect-melissadata.js | ||
test-tls-reuse-host-from-socket.js | ||
test-trace-events-dns.js | ||
test-uv-threadpool-schedule.js | ||
testcfg.py |