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

Fix done.fail not passing arguments #3241

Merged
merged 2 commits into from
Apr 3, 2017

Conversation

thymikee
Copy link
Collaborator

@thymikee thymikee commented Apr 1, 2017

Summary

Fixes done.fail() not passing arguments. Arrow functions don't bind arguments, so I used a regular function instead.
Thanks @jwbay.

Test plan

Added a test for that.

};
await queueRunner(options);

expect(options.fail).toHaveBeenCalledWith('miserably', 'failed');
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

@jwbay it gets called now!

@codecov-io
Copy link

Codecov Report

Merging #3241 into master will decrease coverage by 0.58%.
The diff coverage is 50%.

Impacted file tree graph

@@            Coverage Diff            @@
##           master   #3241      +/-   ##
=========================================
- Coverage   64.19%   63.6%   -0.59%     
=========================================
  Files         141     175      +34     
  Lines        5457    6433     +976     
  Branches        4       4              
=========================================
+ Hits         3503    4092     +589     
- Misses       1953    2340     +387     
  Partials        1       1
Impacted Files Coverage Δ
packages/jest-jasmine2/src/treeProcessor.js 0% <0%> (ø) ⬆️
packages/jest-jasmine2/src/queueRunner.js 100% <100%> (ø) ⬆️
packages/jest-config/src/deprecated.js 85.71% <0%> (-7.62%) ⬇️
packages/jest-cli/src/constants.js 100% <0%> (ø) ⬆️
...uto-clear-mocks/with-auto-clear/__tests__/index.js
flow-typed/console.js
integration_tests/test-in-root/spec.js
..._tests/coverage_report/__mocks__/sum_dependency.js
examples/getting_started/sum.js
packages/jest-cli/src/lib/__tests__/setState.js
... and 46 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 38ca942...36991a0. Read the comment docs.

@thymikee thymikee requested a review from aaronabramov April 3, 2017 20:00
@aaronabramov aaronabramov merged commit 2414d23 into jestjs:master Apr 3, 2017
@thymikee thymikee deleted the fix-done-fail branch April 19, 2017 02:51
skovhus pushed a commit to skovhus/jest that referenced this pull request Apr 29, 2017
* Fix done.fail context issue

* Use concat instead of spread to fix node 4
tushardhole pushed a commit to tushardhole/jest that referenced this pull request Aug 21, 2017
* Fix done.fail context issue

* Use concat instead of spread to fix node 4
@github-actions
Copy link

This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
Please note this issue tracker is not a help forum. We recommend using StackOverflow or our discord channel for questions.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 13, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants