Skip to content

test: fix flaky test-http-server-consumed-timeout

Rodrigo Muino Tomonari requested to merge github/fork/Trott/http-timeout into master
Checklist
  • make -j4 test (UNIX), or vcbuild test nosign (Windows) passes
  • tests and/or benchmarks are included
  • commit message follows commit guidelines
Affected core subsystem(s)

test http

Description of change

Using identical timeout values appears to have eliminated the flakiness in the test.

Fixes: https://github.com/nodejs/node/issues/7643

With this change to the test and removing the fix in https://github.com/nodejs/node/pull/6286, everything fails (as it should): https://ci.nodejs.org/job/node-stress-single-test/804/ (Test run just once on each platform)

With this change to the test only, everything passes (as it should): https://ci.nodejs.org/job/node-stress-single-test/805/ (Test run 100 times on each platform)

And with this change, the test is not flaky on FreeBSD: https://ci.nodejs.org/job/node-stress-single-test/806/nodes=freebsd10-64/console (9999 runs, 0 failures)

For comparison, the test is flaky on current master on FreeBSD: https://ci.nodejs.org/job/node-stress-single-test/807/nodes=freebsd10-64/console (also 9999 runs, 1 failure, so not the overwhelming results I was hoping for, but at least it wasn't 0 failures...)

/cc @indutny

The flakiness is not terribly reproducible in the stress tests, but if it stands to reason that this reduces any race condition window, then it's probably worth doing.

Merge request reports

Loading