node/test/async-hooks
James M Snell ef2ed71389
test: rely less on duplicative common test harness utilities
There are several cleanups here that are not just style nits...

1. The `common.isMainThread` was just a passthrough to the
   `isMainThread` export on the worker_thread module. It's
   use was inconsistent and just obfuscated the fact that
   the test file depend on the `worker_threads` built-in.
   By eliminating it we simplify the test harness a bit and
   make it clearer which tests depend on the worker_threads
   check.
2. The `common.isDumbTerminal` is fairly unnecesary since
   that just wraps a public API check.
3. Several of the `common.skipIf....` checks were inconsistently
   used and really don't need to be separate utility functions.

A key part of the motivation here is to work towards making more
of the tests more self-contained and less reliant on the common
test harness where possible.

PR-URL: https://github.com/nodejs/node/pull/56712
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
2025-01-30 10:44:34 +01:00
..
async-hooks.status test: remove async-hooks/test-writewrap flaky designation 2025-01-02 15:13:19 +01:00
coverage.md
hook-checks.js tools: fix jsdoc lint 2023-05-02 00:48:20 +00:00
init-hooks.js test: rely less on duplicative common test harness utilities 2025-01-30 10:44:34 +01:00
test-async-await.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-async-exec-resource-http-32060.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-async-exec-resource-http-agent.js test: add http agent to `executionAsyncResource` 2024-05-11 10:45:09 +02:00
test-async-exec-resource-http.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-async-exec-resource-match.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-async-local-storage-args.js
test-async-local-storage-async-await.js
test-async-local-storage-async-functions.js
test-async-local-storage-dgram.js
test-async-local-storage-enable-disable.js
test-async-local-storage-enter-with.js
test-async-local-storage-errors.js
test-async-local-storage-gcable.js test: merge ongc and gcutil into gc.js 2024-08-29 08:49:52 +01:00
test-async-local-storage-http-agent.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-async-local-storage-http.js
test-async-local-storage-misc-stores.js
test-async-local-storage-nested.js
test-async-local-storage-no-mix-contexts.js
test-async-local-storage-promises.js
test-async-local-storage-socket.js
test-async-local-storage-thenable.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-async-local-storage-tlssocket.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-async-wrap-providers.js
test-callback-error.js test: add `escapePOSIXShell` util 2024-09-29 20:44:52 +00:00
test-crypto-pbkdf2.js test: rely less on duplicative common test harness utilities 2025-01-30 10:44:34 +01:00
test-crypto-randomBytes.js test: rely less on duplicative common test harness utilities 2025-01-30 10:44:34 +01:00
test-destroy-not-blocked.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-disable-in-init.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-embedder.api.async-resource-no-type.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-embedder.api.async-resource.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-embedder.api.async-resource.runInAsyncScope.js
test-emit-after-on-destroyed.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-emit-before-after.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-emit-before-on-destroyed.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-emit-init.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-enable-disable.js test: rely less on duplicative common test harness utilities 2025-01-30 10:44:34 +01:00
test-enable-in-init.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-filehandle-no-reuse.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-fseventwrap.js test: rely less on duplicative common test harness utilities 2025-01-30 10:44:34 +01:00
test-fsreqcallback-access.js
test-fsreqcallback-readFile.js test: rely less on duplicative common test harness utilities 2025-01-30 10:44:34 +01:00
test-getaddrinforeqwrap.js test: rely less on duplicative common test harness utilities 2025-01-30 10:44:34 +01:00
test-getnameinforeqwrap.js test: rely less on duplicative common test harness utilities 2025-01-30 10:44:34 +01:00
test-graph.fsreq-readFile.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-graph.http.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-graph.intervals.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-graph.pipe.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-graph.pipeconnect.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-graph.shutdown.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-graph.signal.js test: rely less on duplicative common test harness utilities 2025-01-30 10:44:34 +01:00
test-graph.statwatcher.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-graph.tcp.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-graph.timeouts.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-graph.tls-write-12.js
test-graph.tls-write.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-http-agent-handle-reuse-parallel.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-http-agent-handle-reuse-serial.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-httpparser-reuse.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-httpparser.request.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-httpparser.response.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-immediate.js
test-improper-order.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-improper-unwind.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-late-hook-enable.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-net-get-connections.js
test-nexttick-default-trigger.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-no-assert-when-disabled.js test: rely less on duplicative common test harness utilities 2025-01-30 10:44:34 +01:00
test-pipeconnectwrap.js
test-pipewrap.js test: rely less on duplicative common test harness utilities 2025-01-30 10:44:34 +01:00
test-promise.chain-promise-before-init-hooks.js test: rely less on duplicative common test harness utilities 2025-01-30 10:44:34 +01:00
test-promise.js test: rely less on duplicative common test harness utilities 2025-01-30 10:44:34 +01:00
test-promise.promise-before-init-hooks.js
test-querywrap.js
test-queue-microtask.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-shutdownwrap.js
test-signalwrap.js test: rely less on duplicative common test harness utilities 2025-01-30 10:44:34 +01:00
test-statwatcher.js test: rely less on duplicative common test harness utilities 2025-01-30 10:44:34 +01:00
test-tcpwrap.js test: defer invocation checks 2022-11-05 19:53:24 +01:00
test-timers.setInterval.js
test-timers.setTimeout.js
test-tlswrap.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-ttywrap.readstream.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
test-udpsendwrap.js
test-udpwrap.js
test-unhandled-exception-valid-ids.js
test-unhandled-rejection-context.js test: rely less on duplicative common test harness utilities 2025-01-30 10:44:34 +01:00
test-writewrap.js
test-zlib.zlib-binding.deflate.js test: add trailing commas in async-hooks tests (#45549) 2022-11-21 18:43:47 +01:00
testcfg.py
verify-graph.js lib: prefer logical assignment 2024-10-09 06:42:16 +00:00