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(testing): correctly throw in constructor with spy() #5139

Merged
merged 4 commits into from
Jun 26, 2024

Conversation

kt3k
Copy link
Member

@kt3k kt3k commented Jun 25, 2024

Currently thrown error from constructor is not captured by spy. This PR enables spying thrown errors from constructor.

Copy link

codecov bot commented Jun 25, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 93.03%. Comparing base (876c20f) to head (42e69eb).
Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #5139      +/-   ##
==========================================
+ Coverage   93.02%   93.03%   +0.01%     
==========================================
  Files         473      473              
  Lines       38061    38062       +1     
  Branches     5406     5407       +1     
==========================================
+ Hits        35405    35411       +6     
+ Misses       2605     2600       -5     
  Partials       51       51              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@iuioiua iuioiua changed the title fix(testing): spy throwing constructor correctly fix(testing): correctly throw in constructor with spy() Jun 25, 2024
Copy link
Collaborator

@iuioiua iuioiua left a comment

Choose a reason for hiding this comment

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

Nice

@kt3k kt3k merged commit 06d4390 into denoland:main Jun 26, 2024
15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants