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

Refactor test-stream-writable-clear-buffer #30561

Closed
wants to merge 0 commits into from

Conversation

@Trott
Copy link
Member

Trott commented Nov 20, 2019

  • replace setTimeout() with setImmediate()

    Replace setTimeout() with setImmediate() in
    test-stream-writable-clear-buffer. The test still fails in Node.js 8.6.0
    (if you comment out the common module, since it uses BigInts and those
    aren't supported in 8.6.0).

  • use arrow function for anonymous callback

  • remove literal as message in assert.strictEqual()

    This reveals the values that cause the assertion error, should it
    happen.

  • move from sequential to parallel

    I don't believe there's a reason test-stream-writable-clear-buffer needs
    to be in sequential. Move it to parallel.

I tried to make it fail locally in parallel with tools/test.py -j 96 --repeat 192 test/parallel/test-stream-writable-clear-buffer.js but it passed and ran very quickly.

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • commit message follows commit guidelines
@nodejs-github-bot

This comment has been minimized.

Copy link
Member

addaleax left a comment

This doesn’t fix flakiness, does it? (Just asking because I’d be surprised if the test was flaky in its previous form)

test/parallel/test-stream-writable-clear-buffer.js Outdated Show resolved Hide resolved
@Trott

This comment has been minimized.

Copy link
Member Author

Trott commented Nov 20, 2019

This doesn’t fix flakiness, does it? (Just asking because I’d be surprised if the test was flaky in its previous form)

No, it does not fix flakiness to my knowledge. It's just some improvements and getting it moved into parallel.

Trott added a commit to Trott/io.js that referenced this pull request Nov 20, 2019
@Trott Trott force-pushed the Trott:refactor-stream-test branch from affcba4 to e6d0107 Nov 20, 2019
@nodejs-github-bot

This comment has been minimized.

@Trott Trott added the author ready label Nov 20, 2019
@nodejs-github-bot

This comment has been minimized.

Trott added a commit to Trott/io.js that referenced this pull request Nov 22, 2019
Replace setTimeout() with setImmediate() in
test-stream-writable-clear-buffer. The test still fails in Node.js 8.6.0
(if you comment out the `common` module, since it uses BigInts and those
aren't supported in 8.6.0).

PR-URL: nodejs#30561
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Trott added a commit to Trott/io.js that referenced this pull request Nov 22, 2019
PR-URL: nodejs#30561
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Trott added a commit to Trott/io.js that referenced this pull request Nov 22, 2019
This reveals the values that cause the assertion error, should it
happen.

PR-URL: nodejs#30561
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Trott added a commit to Trott/io.js that referenced this pull request Nov 22, 2019
I don't believe there's a reason test-stream-writable-clear-buffer needs
to be in sequential. Move it to parallel.

PR-URL: nodejs#30561
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Trott added a commit to Trott/io.js that referenced this pull request Nov 22, 2019
Refs: nodejs#30561 (review)

PR-URL: nodejs#30561
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Trott added a commit to Trott/io.js that referenced this pull request Nov 22, 2019
Refs: https://github.com/nodejs/node/pull/30561/files#r348667256

PR-URL: nodejs#30561
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
@Trott

This comment has been minimized.

Copy link
Member Author

Trott commented Nov 22, 2019

Landed in b703218...19e44ef

@Trott Trott closed this Nov 22, 2019
@Trott Trott force-pushed the Trott:refactor-stream-test branch from da7be1d to 19e44ef Nov 22, 2019
@Trott Trott deleted the Trott:refactor-stream-test branch Nov 22, 2019
addaleax added a commit that referenced this pull request Nov 30, 2019
Replace setTimeout() with setImmediate() in
test-stream-writable-clear-buffer. The test still fails in Node.js 8.6.0
(if you comment out the `common` module, since it uses BigInts and those
aren't supported in 8.6.0).

PR-URL: #30561
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
addaleax added a commit that referenced this pull request Nov 30, 2019
PR-URL: #30561
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
addaleax added a commit that referenced this pull request Nov 30, 2019
This reveals the values that cause the assertion error, should it
happen.

PR-URL: #30561
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
addaleax added a commit that referenced this pull request Nov 30, 2019
I don't believe there's a reason test-stream-writable-clear-buffer needs
to be in sequential. Move it to parallel.

PR-URL: #30561
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
addaleax added a commit that referenced this pull request Nov 30, 2019
Refs: #30561 (review)

PR-URL: #30561
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
addaleax added a commit that referenced this pull request Nov 30, 2019
Refs: https://github.com/nodejs/node/pull/30561/files#r348667256

PR-URL: #30561
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
targos added a commit that referenced this pull request Dec 1, 2019
Replace setTimeout() with setImmediate() in
test-stream-writable-clear-buffer. The test still fails in Node.js 8.6.0
(if you comment out the `common` module, since it uses BigInts and those
aren't supported in 8.6.0).

PR-URL: #30561
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
targos added a commit that referenced this pull request Dec 1, 2019
PR-URL: #30561
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
targos added a commit that referenced this pull request Dec 1, 2019
This reveals the values that cause the assertion error, should it
happen.

PR-URL: #30561
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
targos added a commit that referenced this pull request Dec 1, 2019
I don't believe there's a reason test-stream-writable-clear-buffer needs
to be in sequential. Move it to parallel.

PR-URL: #30561
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
targos added a commit that referenced this pull request Dec 1, 2019
Refs: #30561 (review)

PR-URL: #30561
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
targos added a commit that referenced this pull request Dec 1, 2019
Refs: https://github.com/nodejs/node/pull/30561/files#r348667256

PR-URL: #30561
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
@BridgeAR BridgeAR mentioned this pull request Dec 3, 2019
@BethGriggs BethGriggs mentioned this pull request Dec 9, 2019
MylesBorins added a commit that referenced this pull request Dec 17, 2019
Replace setTimeout() with setImmediate() in
test-stream-writable-clear-buffer. The test still fails in Node.js 8.6.0
(if you comment out the `common` module, since it uses BigInts and those
aren't supported in 8.6.0).

PR-URL: #30561
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
MylesBorins added a commit that referenced this pull request Dec 17, 2019
PR-URL: #30561
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
MylesBorins added a commit that referenced this pull request Dec 17, 2019
This reveals the values that cause the assertion error, should it
happen.

PR-URL: #30561
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
MylesBorins added a commit that referenced this pull request Dec 17, 2019
I don't believe there's a reason test-stream-writable-clear-buffer needs
to be in sequential. Move it to parallel.

PR-URL: #30561
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
MylesBorins added a commit that referenced this pull request Dec 17, 2019
Refs: #30561 (review)

PR-URL: #30561
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
MylesBorins added a commit that referenced this pull request Dec 17, 2019
Refs: https://github.com/nodejs/node/pull/30561/files#r348667256

PR-URL: #30561
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
@BethGriggs BethGriggs mentioned this pull request Dec 23, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants
You can’t perform that action at this time.