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): cause type error for async function as describe body #5355

Merged
merged 1 commit into from
Jul 9, 2024

Conversation

kt3k
Copy link
Member

@kt3k kt3k commented Jul 8, 2024

Partially addresses #5034

This changes uses () => void | undefined type for describe body type instead of () => void, which causes type error if the user assigned async functions to it.

This will prevents the confusion like denoland/deno#22991

Copy link

codecov bot commented Jul 8, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 96.24%. Comparing base (0d668fa) to head (6066ed5).

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #5355   +/-   ##
=======================================
  Coverage   96.24%   96.24%           
=======================================
  Files         458      458           
  Lines       37849    37849           
  Branches     5608     5608           
=======================================
  Hits        36427    36427           
  Misses       1381     1381           
  Partials       41       41           

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

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 6eeddb3 into denoland:main Jul 9, 2024
13 checks passed
@kt3k kt3k deleted the fix-testing-type-error-with-async-fn branch July 9, 2024 03:13
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.

2 participants