Skip to content

test: fix asyncworker test so it runs on 6.x#298

Closed
mhdawson wants to merge 1 commit intonodejs:masterfrom
mhdawson:fix6
Closed

test: fix asyncworker test so it runs on 6.x#298
mhdawson wants to merge 1 commit intonodejs:masterfrom
mhdawson:fix6

Conversation

@mhdawson
Copy link
Copy Markdown
Member

Fixes: #296

@mhdawson
Copy link
Copy Markdown
Member Author

@gabrielschulhof can you please review/approve.

@gabrielschulhof
Copy link
Copy Markdown
Contributor

Maybe we should refine this to perform the async work irrespective of whether hooks are available or not, but to not create, nor check the result of the promise if the hooks are unavailable.

Copy link
Copy Markdown
Member

@NickNaso NickNaso left a comment

Choose a reason for hiding this comment

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

LGTM

@mhdawson
Copy link
Copy Markdown
Member Author

@gabrielschulhof I think it now does what you suggested. It checks which version its running on and runs different tests on 6.x.

Copy link
Copy Markdown
Contributor

@gabrielschulhof gabrielschulhof left a comment

Choose a reason for hiding this comment

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

@mhdawson oh, you're right. I read the diff wrong. Its behaviour is unchanged if the async_hooks are present, and doing merely the async work is the addition.

@mhdawson
Copy link
Copy Markdown
Member Author

Going to land this without waiting the usual 48 hours as it fixes a regression and we have 2 approvals.

@mhdawson
Copy link
Copy Markdown
Member Author

Also as an FYI, figured out how to have a run of the tests nightly on all of the LTS versions. Job is here: https://ci.nodejs.org/view/x%20-%20Abi%20stable%20module%20API/job/node-test-node-addon-api-LTS%20versions/

The way it reports failures is not great as it's not clear which version the failure was on, but at least its a start and the info is available if you look at the console output for the top level job.

mhdawson added a commit that referenced this pull request Jul 11, 2018
PR-URL: #298
Fixes: #296
Reviewed-By: Gabriel Schulhof <gabriel.schulhof@intel.com>
Reviewed-By: Nicola Del Gobbo <nicoladelgobbo@NickNaso.local>
@mhdawson
Copy link
Copy Markdown
Member Author

Landed as dd1191e

@mhdawson mhdawson closed this Jul 11, 2018
kevindavies8 added a commit to kevindavies8/node-addon-api-Develop that referenced this pull request Aug 24, 2022
PR-URL: nodejs/node-addon-api#298
Fixes: nodejs/node-addon-api#296
Reviewed-By: Gabriel Schulhof <gabriel.schulhof@intel.com>
Reviewed-By: Nicola Del Gobbo <nicoladelgobbo@NickNaso.local>
Marlyfleitas added a commit to Marlyfleitas/node-api-addon-Development that referenced this pull request Aug 26, 2022
PR-URL: nodejs/node-addon-api#298
Fixes: nodejs/node-addon-api#296
Reviewed-By: Gabriel Schulhof <gabriel.schulhof@intel.com>
Reviewed-By: Nicola Del Gobbo <nicoladelgobbo@NickNaso.local>
wroy7860 added a commit to wroy7860/addon-api-benchmark-node that referenced this pull request Sep 19, 2022
PR-URL: nodejs/node-addon-api#298
Fixes: nodejs/node-addon-api#296
Reviewed-By: Gabriel Schulhof <gabriel.schulhof@intel.com>
Reviewed-By: Nicola Del Gobbo <nicoladelgobbo@NickNaso.local>
johnfrench3 pushed a commit to johnfrench3/node-addon-api-git that referenced this pull request Aug 11, 2023
PR-URL: nodejs/node-addon-api#298
Fixes: nodejs/node-addon-api#296
Reviewed-By: Gabriel Schulhof <gabriel.schulhof@intel.com>
Reviewed-By: Nicola Del Gobbo <nicoladelgobbo@NickNaso.local>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants