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

Update to mocha 7 #8108

Merged
merged 6 commits into from Mar 31, 2020
Merged

Update to mocha 7 #8108

merged 6 commits into from Mar 31, 2020

Conversation

xirzec
Copy link
Member

@xirzec xirzec commented Mar 30, 2020

Thanks to @HarshaNalluru in #7931 we now can upgrade Mocha to the latest version.

Fixes #7932

@xirzec
Copy link
Member Author

xirzec commented Mar 31, 2020

I think this fixes #5697 as well

@@ -57,8 +57,10 @@ describe("FileClient", () => {
});

afterEach(async function() {
await shareClient.delete();
recorder.stop();
if (!this.currentTest?.isPending()) {
Copy link
Member

Choose a reason for hiding this comment

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

Why this?
afterEach would anyway be executed only after the current test ends, right?

Copy link
Member Author

Choose a reason for hiding this comment

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

Well issuing a delete breaks the recording, since the test was skipped and we didn't record that operation. We could also blanketly re-record everything, but it feels weird to do cleanup on skipped tests

Copy link
Member

Choose a reason for hiding this comment

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

Ah, got the problem...
Previously, afterEach was skipped if the test is skipped, but with mocha@7.0.0, afterEach gets executed even if the test is skipped.
This is fine here, we can fix these in a followup issue.. #8110

@HarshaNalluru
Copy link
Member

/azp run js - servicebus - tests

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@HarshaNalluru
Copy link
Member

HarshaNalluru commented Mar 31, 2020

/azp run js - eventhubs-client - tests

@azure-pipelines
Copy link

No pipelines are associated with this pull request.

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@HarshaNalluru
Copy link
Member

/azp run js - storage-blob - tests

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

Copy link
Member

@HarshaNalluru HarshaNalluru left a comment

Choose a reason for hiding this comment

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

Assuming all the checks are green(even the live tests)..!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Azure.Core Client This issue points to a problem in the data-plane of the library.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Update mocha to 7.0.0
2 participants