node/test/sequential
Rich Trott be8274508c test: improve test-cluster-disconnect-suicide-race
Previously, test-cluster-disconnect-suicide-race had two issues:

* Magic numbers: How many times to spawn a worker was determined through
empirical experimentation. This means that as new platforms and new
CPU/RAM configurations are tested, the magic numbers require more
and more refinement. This brings us to...

* Non-determinism: The test seems to fail all the time when the bug
it tests for is present, but it's really a judgment based on sampling.
"Oh, with 8 workers per CPU, it fails about 80% of the time. Let's try
16..."

This revised version of the test takes a different approach. The fix
for the bug that the test was written for means that the disconnect
event will fire on a subsequent tick. So we check for that and the test
still fails when the fix is not in the code base and succeeds when it
is.

Advantages of this approach include:

* The test runs much faster.
* The test should be reliable on any new platform regardless of CPU and
RAM.

PR-URL: https://github.com/nodejs/node/pull/4739
Ref: https://github.com/nodejs/node/pull/4674
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: James M Snell <jasnell@gmail.com>
2016-02-15 11:30:23 -08:00
..
sequential.status test: repl-persistent-history is no longer flaky 2015-10-29 08:38:41 -07:00
test-child-process-emfile.js test: fix flaky test-child-process-emfile 2015-10-29 08:38:41 -07:00
test-child-process-execsync.js test: fix style issues after eslint update 2016-02-15 11:30:23 -08:00
test-child-process-fork-getconnections.js lib,test: update let to const where applicable 2016-01-19 11:52:11 -08:00
test-cluster-disconnect-leak.js test: make test-cluster-disconnect-leak reliable 2016-02-15 11:30:23 -08:00
test-cluster-disconnect-suicide-race.js test: improve test-cluster-disconnect-suicide-race 2016-02-15 11:30:23 -08:00
test-cluster-listening-port.js test: wrap assert.fail when passed to callback 2015-10-29 08:38:42 -07:00
test-debug-args.js test: remove unnecessary assignments 2016-01-19 11:52:30 -08:00
test-deprecation-flags.js test: remove unnecessary assignments 2016-01-19 11:52:30 -08:00
test-dgram-pingpong.js test: move resource intensive tests to sequential 2016-02-15 11:30:23 -08:00
test-force-repl.js test: enable linting for tests 2015-05-19 21:21:27 +02:00
test-fs-watch.js test: split independent tests into separate files 2015-10-30 10:07:47 -07:00
test-http-regr-gh-2928.js test: move resource intensive tests to sequential 2016-02-15 11:30:23 -08:00
test-init.js test: fix style issues after eslint update 2016-02-15 11:30:23 -08:00
test-memory-usage-emfile.js test: remove unnecessary assignments 2016-01-19 11:52:30 -08:00
test-module-loading.js test: fix style issues after eslint update 2016-02-15 11:30:23 -08:00
test-net-GH-5504.js test: extend timeout in Debug mode 2016-01-19 11:52:40 -08:00
test-net-listen-exclusive-random-ports.js test: remove unnecessary assignments 2016-01-19 11:52:30 -08:00
test-net-localport.js test: enable linting for tests 2015-05-19 21:21:27 +02:00
test-net-server-address.js test: skip IPv6 part before testing it 2015-07-27 23:24:03 +05:30
test-net-server-bind.js test: enable linting for tests 2015-05-19 21:21:27 +02:00
test-next-tick-error-spin.js test: enable linting for tests 2015-05-19 21:21:27 +02:00
test-pipe-address.js test: refresh temp directory when using pipe 2015-10-10 10:38:55 -07:00
test-pipe-head.js test: enable linting for tests 2015-05-19 21:21:27 +02:00
test-pipe-stream.js test: refresh temp directory when using pipe 2015-10-10 10:38:55 -07:00
test-pipe-unref.js test: refresh temp directory when using pipe 2015-10-10 10:38:55 -07:00
test-pipe.js lib,test: fix whitespace issues 2015-06-15 16:37:37 +02:00
test-pump-file2tcp-noexist.js test: remove deprecated error logging 2015-10-07 20:39:18 -07:00
test-pump-file2tcp.js test: remove unused vars 2016-01-19 11:52:39 -08:00
test-regress-GH-746.js test: enable linting for tests 2015-05-19 21:21:27 +02:00
test-regress-GH-784.js lib,test: fix whitespace issues 2015-06-15 16:37:37 +02:00
test-regress-GH-819.js test: remove unused assert module imports 2016-01-19 11:52:33 -08:00
test-regress-GH-877.js test: enable linting for tests 2015-05-19 21:21:27 +02:00
test-regress-GH-1531.js test: changing process.exit to return while skipping tests 2015-07-20 15:50:42 +05:30
test-regress-GH-1697.js test: fix style issues after eslint update 2016-02-15 11:30:23 -08:00
test-regress-GH-1726.js test: remove unnecessary assignments 2016-01-19 11:52:30 -08:00
test-regress-GH-1899.js test: enable linting for tests 2015-05-19 21:21:27 +02:00
test-regress-GH-3542.js test: fix style issues after eslint update 2016-02-15 11:30:23 -08:00
test-regress-GH-4015.js test: enable linting for tests 2015-05-19 21:21:27 +02:00
test-regress-GH-4027.js test: only refresh tmpDir for tests that need it 2015-06-13 22:27:17 -07:00
test-regress-GH-4948.js lib,test: fix whitespace issues 2015-06-15 16:37:37 +02:00
test-require-cache-without-stat.js test: enable linting for tests 2015-05-19 21:21:27 +02:00
test-setproctitle.js test: remove unnecessary assignments 2016-01-19 11:52:30 -08:00
test-sigint-infinite-loop.js test: remove unnecessary assignments 2016-01-19 11:52:30 -08:00
test-socket-write-after-fin-error.js test: enable linting for tests 2015-05-19 21:21:27 +02:00
test-socket-write-after-fin.js test: enable linting for tests 2015-05-19 21:21:27 +02:00
test-stdin-child-proc.js test: remove unnecessary assignments 2016-01-19 11:52:30 -08:00
test-stdin-from-file.js test: correct spelling of 'childProcess' 2015-08-17 20:55:19 +02:00
test-stdin-pipe-resume.js test: remove unnecessary assignments 2016-01-19 11:52:30 -08:00
test-stdin-script-child.js test: remove unnecessary assignments 2016-01-19 11:52:30 -08:00
test-stdout-cannot-be-closed-child-process-pipe.js test: remove unnecessary assignments 2016-01-19 11:52:30 -08:00
test-stdout-close-catch.js test: remove unused modules 2016-01-19 11:52:39 -08:00
test-stdout-stderr-reading.js test: remove unnecessary assignments 2016-01-19 11:52:30 -08:00
test-stdout-to-file.js test: change calls to deprecated util.print() 2015-09-30 22:19:52 +10:00
test-stream2-fs.js test: remove unused vars 2016-01-19 11:52:39 -08:00
test-stream2-httpclient-response-end.js test: enable linting for tests 2015-05-19 21:21:27 +02:00
test-stream2-stderr-sync.js test: remove unused assert module imports 2016-01-19 11:52:33 -08:00
test-stringbytes-external-exceed-max-by-1-ascii.js test: move resource intensive tests to sequential 2016-02-15 11:30:23 -08:00
test-stringbytes-external-exceed-max-by-1-base64.js test: move resource intensive tests to sequential 2016-02-15 11:30:23 -08:00
test-stringbytes-external-exceed-max-by-1-binary.js test: move resource intensive tests to sequential 2016-02-15 11:30:23 -08:00
test-stringbytes-external-exceed-max-by-1-hex.js test: move resource intensive tests to sequential 2016-02-15 11:30:23 -08:00
test-stringbytes-external-exceed-max-by-1-utf8.js test: move resource intensive tests to sequential 2016-02-15 11:30:23 -08:00
test-stringbytes-external-exceed-max-by-2.js test: move resource intensive tests to sequential 2016-02-15 11:30:23 -08:00
test-stringbytes-external-exceed-max.js test: move resource intensive tests to sequential 2016-02-15 11:30:23 -08:00
test-sync-fileread.js test: remove unnecessary assignments 2016-01-19 11:52:30 -08:00
test-tcp-wrap-connect.js test: enable linting for tests 2015-05-19 21:21:27 +02:00
test-tcp-wrap-listen.js test: remove unused vars 2016-01-19 11:52:39 -08:00
test-tls-honorcipherorder.js test: skip/replace weak crypto tests in FIPS mode 2015-12-23 08:38:33 -08:00
test-util-debug.js test: remove unnecessary assignments 2016-01-19 11:52:30 -08:00
test-vm-syntax-error-stderr.js node: do not override message/stack of error 2015-08-04 11:56:16 -07:00
test-vm-timeout-rethrow.js test: load common.js to test for global leaks 2015-10-02 13:39:27 +10:00
test-zerolengthbufferbug.js test: enable linting for tests 2015-05-19 21:21:27 +02:00
testcfg.py