-
Notifications
You must be signed in to change notification settings - Fork 38
test: Mute deprecation warnings #293
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
base: master
Are you sure you want to change the base?
Conversation
fc4f2d1
to
074678d
Compare
👋 Hi! This pull request has been marked stale due to inactivity. If no further activity occurs, it will automatically be closed. |
const temp = deprecation; | ||
deprecation = null; | ||
return temp; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we have to worry about race conditions here? Can mocha run tests simultaneously?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
By default mocha runs test serially. So in step 12 it describes the flow of execution:
So I don't think there would be issue of tests running simultaneously unless we were using parallel mode
Mute deprecation warnings by capturing the deprecation event emitted by the process with:
process.on('deprecation', fn)
Within the test cases we ensure that the deprecated functions emit a deprecation warning.
Resolves #150