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 asyncworker test so it runs on 6.x #298

Closed
wants to merge 1 commit into from

Conversation

mhdawson
Copy link
Member

Fixes: #296

@mhdawson
Copy link
Member Author

@gabrielschulhof can you please review/approve.

@gabrielschulhof
Copy link
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
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
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
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
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
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 <[email protected]>
Reviewed-By: Nicola Del Gobbo <[email protected]>
@mhdawson
Copy link
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
Marlyfleitas added a commit to Marlyfleitas/node-api-addon-Development that referenced this pull request Aug 26, 2022
wroy7860 added a commit to wroy7860/addon-api-benchmark-node that referenced this pull request Sep 19, 2022
johnfrench3 pushed a commit to johnfrench3/node-addon-api-git that referenced this pull request Aug 11, 2023
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