Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test: fix flaky test-https-timeout #10404

Closed
wants to merge 1 commit into from
Closed

Conversation

Trott
Copy link
Member

@Trott Trott commented Dec 22, 2016

Remove setTimeout() in test and instead rely on common.mustCall() on
a timeout event handler.

The test was flaky on CI. The flakiness was replicable by running the
test under load. This version, in contrast, is robust under load.

Took the opportunity to do some var -> const while refactoring.

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • commit message follows commit guidelines
Affected core subsystem(s)

test https

Description of change

@Trott Trott added https Issues or PRs related to the https subsystem. test Issues and PRs related to the tests. labels Dec 22, 2016
@Trott
Copy link
Member Author

Trott commented Dec 22, 2016

Example failure of the current version in CI:

https://ci.nodejs.org/job/node-test-commit-freebsd/6013/nodes=freebsd10-64/console:

not ok 621 parallel/test-https-timeout
  ---
  duration_ms: 1.93
  severity: fail
  stack: |-
    got a socket
    socket connected
    /usr/home/iojs/build/workspace/node-test-commit-freebsd/nodes/freebsd10-64/test/parallel/test-https-timeout.js:43
          throw new Error('Did not get timeout event');
          ^
    
    Error: Did not get timeout event
        at Timeout._onTimeout (/usr/home/iojs/build/workspace/node-test-commit-freebsd/nodes/freebsd10-64/test/parallel/test-https-timeout.js:43:13)
        at ontimeout (timers.js:365:14)
        at tryOnTimeout (timers.js:237:5)
        at Timer.listOnTimeout (timers.js:207:5)
  ...

Remove `setTimeout()` in test and instead rely on `common.mustCall()` on
a `timeout` event handler.

The test was flaky on CI. The flakiness was replicable by running the
test under load. This version, in contrast, is robust under load.

Took the opportunity to do some `var` -> `const` while refactoring.
@Trott
Copy link
Member Author

Trott commented Dec 22, 2016

Stress test under load showing current master branch version of this test failing:
https://ci.nodejs.org/job/node-stress-single-test/1091/nodes=freebsd10-64/console

Stress test under load with this version of the test showing it passing:
https://ci.nodejs.org/job/node-stress-single-test/1092/nodes=freebsd10-64/console

@Trott
Copy link
Member Author

Trott commented Dec 22, 2016

Trott added a commit to Trott/io.js that referenced this pull request Dec 24, 2016
Remove `setTimeout()` in test and instead rely on `common.mustCall()` on
a `timeout` event handler.

The test was flaky on CI. The flakiness was replicable by running the
test under load. This version, in contrast, is robust under load.

Took the opportunity to do some `var` -> `const` while refactoring.

PR-URL: nodejs#10404
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Italo A. Casas <me@italoacasas.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
@Trott
Copy link
Member Author

Trott commented Dec 24, 2016

Landed in 3f52ce3

@Trott Trott closed this Dec 24, 2016
evanlucas pushed a commit that referenced this pull request Jan 3, 2017
Remove `setTimeout()` in test and instead rely on `common.mustCall()` on
a `timeout` event handler.

The test was flaky on CI. The flakiness was replicable by running the
test under load. This version, in contrast, is robust under load.

Took the opportunity to do some `var` -> `const` while refactoring.

PR-URL: #10404
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Italo A. Casas <me@italoacasas.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
evanlucas pushed a commit that referenced this pull request Jan 4, 2017
Remove `setTimeout()` in test and instead rely on `common.mustCall()` on
a `timeout` event handler.

The test was flaky on CI. The flakiness was replicable by running the
test under load. This version, in contrast, is robust under load.

Took the opportunity to do some `var` -> `const` while refactoring.

PR-URL: #10404
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Italo A. Casas <me@italoacasas.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
MylesBorins pushed a commit that referenced this pull request Jan 23, 2017
Remove `setTimeout()` in test and instead rely on `common.mustCall()` on
a `timeout` event handler.

The test was flaky on CI. The flakiness was replicable by running the
test under load. This version, in contrast, is robust under load.

Took the opportunity to do some `var` -> `const` while refactoring.

PR-URL: #10404
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Italo A. Casas <me@italoacasas.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
MylesBorins pushed a commit that referenced this pull request Jan 23, 2017
Remove `setTimeout()` in test and instead rely on `common.mustCall()` on
a `timeout` event handler.

The test was flaky on CI. The flakiness was replicable by running the
test under load. This version, in contrast, is robust under load.

Took the opportunity to do some `var` -> `const` while refactoring.

PR-URL: #10404
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Italo A. Casas <me@italoacasas.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
MylesBorins pushed a commit that referenced this pull request Jan 23, 2017
Remove `setTimeout()` in test and instead rely on `common.mustCall()` on
a `timeout` event handler.

The test was flaky on CI. The flakiness was replicable by running the
test under load. This version, in contrast, is robust under load.

Took the opportunity to do some `var` -> `const` while refactoring.

PR-URL: #10404
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Italo A. Casas <me@italoacasas.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
MylesBorins pushed a commit that referenced this pull request Jan 24, 2017
Remove `setTimeout()` in test and instead rely on `common.mustCall()` on
a `timeout` event handler.

The test was flaky on CI. The flakiness was replicable by running the
test under load. This version, in contrast, is robust under load.

Took the opportunity to do some `var` -> `const` while refactoring.

PR-URL: #10404
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Italo A. Casas <me@italoacasas.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
MylesBorins pushed a commit that referenced this pull request Jan 24, 2017
Remove `setTimeout()` in test and instead rely on `common.mustCall()` on
a `timeout` event handler.

The test was flaky on CI. The flakiness was replicable by running the
test under load. This version, in contrast, is robust under load.

Took the opportunity to do some `var` -> `const` while refactoring.

PR-URL: #10404
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Italo A. Casas <me@italoacasas.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
This was referenced Jan 24, 2017
MylesBorins pushed a commit that referenced this pull request Jan 31, 2017
Remove `setTimeout()` in test and instead rely on `common.mustCall()` on
a `timeout` event handler.

The test was flaky on CI. The flakiness was replicable by running the
test under load. This version, in contrast, is robust under load.

Took the opportunity to do some `var` -> `const` while refactoring.

PR-URL: #10404
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Italo A. Casas <me@italoacasas.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
MylesBorins pushed a commit that referenced this pull request Feb 1, 2017
Remove `setTimeout()` in test and instead rely on `common.mustCall()` on
a `timeout` event handler.

The test was flaky on CI. The flakiness was replicable by running the
test under load. This version, in contrast, is robust under load.

Took the opportunity to do some `var` -> `const` while refactoring.

PR-URL: #10404
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Italo A. Casas <me@italoacasas.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
@Trott Trott deleted the https-timeout branch January 13, 2022 22:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
https Issues or PRs related to the https subsystem. test Issues and PRs related to the tests.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants