Skip to content

test: move timer-dependent test to sequential - #9487

Closed
Trott wants to merge 2 commits into
nodejs:masterfrom
Trott:897
Closed

test: move timer-dependent test to sequential#9487
Trott wants to merge 2 commits into
nodejs:masterfrom
Trott:897

Conversation

@Trott

@TrottTrott commented Nov 6, 2016

Copy link
Copy Markdown
Member
Checklist
  • make -j8 test (UNIX), or vcbuild test nosign (Windows) passes
  • commit message follows commit guidelines
Affected core subsystem(s)

test timers

Description of change

test-regress-GH-897 is dependent on a timer firing within a period of
time. Especially on some of the FreeBSD hosts on CI, we have seen tests
like that fail when run in parallel. (This may have nothing to do with
FreeBSD and may just mean that the hosts are resource-constrained.) Move
this test to sequential as we have done with several other
timer-dependent tests recently.

The test has also been refactored and documented via comments.

`test-regress-nodejsGH-897` is dependent on a timer firing within a period of
time. Especially on some of the FreeBSD hosts on CI, we have seen tests
like that fail when run in parallel. (This may have nothing to do with
FreeBSD and may just mean that the hosts are resource-constrained.) Move
this test to sequential as we have done with several other
timer-dependent tests recently.
The test has also been refactored and documented via comments.
@TrottTrott added timers Issues and PRs related to the timers subsystem / setImmediate, setInterval, setTimeout. test Issues and PRs related to the tests. freebsd Issues and PRs related to the FreeBSD platform. labels Nov 6, 2016
@nodejs-github-botnodejs-github-bot added the test Issues and PRs related to the tests. label Nov 6, 2016
@Trott

Trott commented Nov 6, 2016

Copy link
Copy Markdown
MemberAuthor

@nodejs/testing

const assert = require('assert');

const t = Date.now();
setTimeout(function() {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since you dropped the process.on('exit', ...), this should probably use common.mustCall().

Copy link
Copy Markdown
MemberAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good idea. Done.

@cjihrigcjihrig left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM with one nit.

@Trott

Trott commented Nov 6, 2016

Copy link
Copy Markdown
MemberAuthor

Oh, I should add the example failure: https://ci.nodejs.org/job/node-test-commit-freebsd/5179/nodes=freebsd10-64/

not ok 813 parallel/test-regress-GH-897
# 312
# # assert.js:85
# throw new assert.AssertionError({
# ^
# AssertionError: false == true
# at process.<anonymous> (/usr/home/iojs/build/workspace/node-test-commit-freebsd/nodes/freebsd10-64/test/parallel/test-regress-GH-897.js:14:10)
# at emitOne (events.js:101:20)
# at process.emit (events.js:188:7)
---
duration_ms: 1.72

Trott added a commit to Trott/io.js that referenced this pull request Nov 10, 2016
`test-regress-nodejsGH-897` is dependent on a timer firing within a period of
time. Especially on some of the FreeBSD hosts on CI, we have seen tests
like that fail when run in parallel. (This may have nothing to do with
FreeBSD and may just mean that the hosts are resource-constrained.) Move
this test to sequential as we have done with several other
timer-dependent tests recently.
The test has also been refactored and documented via comments.
PR-URL: nodejs#9487
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Reviewed-By: Minwoo Jung <jmwsoft@gmail.com>
@Trott

Copy link
Copy Markdown
MemberAuthor

Landed in 1ce05ad

@TrottTrott closed this Nov 10, 2016
addaleax pushed a commit that referenced this pull request Nov 22, 2016
`test-regress-GH-897` is dependent on a timer firing within a period of
time. Especially on some of the FreeBSD hosts on CI, we have seen tests
like that fail when run in parallel. (This may have nothing to do with
FreeBSD and may just mean that the hosts are resource-constrained.) Move
this test to sequential as we have done with several other
timer-dependent tests recently.
The test has also been refactored and documented via comments.
PR-URL: #9487
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Reviewed-By: Minwoo Jung <jmwsoft@gmail.com>
addaleax pushed a commit to addaleax/node that referenced this pull request Dec 8, 2016
`test-regress-nodejsGH-897` is dependent on a timer firing within a period of
time. Especially on some of the FreeBSD hosts on CI, we have seen tests
like that fail when run in parallel. (This may have nothing to do with
FreeBSD and may just mean that the hosts are resource-constrained.) Move
this test to sequential as we have done with several other
timer-dependent tests recently.
The test has also been refactored and documented via comments.
PR-URL: nodejs#9487
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Reviewed-By: Minwoo Jung <jmwsoft@gmail.com>
MylesBorins pushed a commit that referenced this pull request Dec 20, 2016
`test-regress-GH-897` is dependent on a timer firing within a period of
time. Especially on some of the FreeBSD hosts on CI, we have seen tests
like that fail when run in parallel. (This may have nothing to do with
FreeBSD and may just mean that the hosts are resource-constrained.) Move
this test to sequential as we have done with several other
timer-dependent tests recently.
The test has also been refactored and documented via comments.
PR-URL: #9487
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Reviewed-By: Minwoo Jung <jmwsoft@gmail.com>
MylesBorins pushed a commit that referenced this pull request Dec 21, 2016
`test-regress-GH-897` is dependent on a timer firing within a period of
time. Especially on some of the FreeBSD hosts on CI, we have seen tests
like that fail when run in parallel. (This may have nothing to do with
FreeBSD and may just mean that the hosts are resource-constrained.) Move
this test to sequential as we have done with several other
timer-dependent tests recently.
The test has also been refactored and documented via comments.
PR-URL: #9487
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Reviewed-By: Minwoo Jung <jmwsoft@gmail.com>
MylesBorins pushed a commit that referenced this pull request Dec 21, 2016
`test-regress-GH-897` is dependent on a timer firing within a period of
time. Especially on some of the FreeBSD hosts on CI, we have seen tests
like that fail when run in parallel. (This may have nothing to do with
FreeBSD and may just mean that the hosts are resource-constrained.) Move
this test to sequential as we have done with several other
timer-dependent tests recently.
The test has also been refactored and documented via comments.
PR-URL: #9487
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Reviewed-By: Minwoo Jung <jmwsoft@gmail.com>
This was referenced Dec 21, 2016
@Trott
Trott deleted the 897 branch January 13, 2022 22:44
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

freebsdIssues and PRs related to the FreeBSD platform.testIssues and PRs related to the tests.timersIssues and PRs related to the timers subsystem / setImmediate, setInterval, setTimeout.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants

@Trott@santigimeno@cjihrig@JungMinu@MylesBorins@addaleax@nodejs-github-bot