-
Notifications
You must be signed in to change notification settings - Fork 5.7k
fix(test): handle snippet containing Deno.test
in doc test
#29631
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
Conversation
2dc9feb
to
d86fd22
Compare
This option sounds confusing to me. How about detecting the usage of |
@kt3k could i get pointers on how to detect |
|
d86fd22
to
9c90317
Compare
@kt3k applied and force-pushed in |
Deno.test
in doc testDeno.test
in doc test
Deno.test
in doc test Deno.test
in doc test
9c90317
to
67b7a32
Compare
67b7a32
to
be81dba
Compare
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.
LGTM
I also like to hear opinions from @bartlomieju @dsherret @nathanwhit
Deno.test
in doc test Deno.test
in doc test
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.
Seems quite niche, but I'm fine with this solution, +1 from me
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.
LGTM too
fixes #29629
skips wrapping code snippet in
Deno.test
if it already has one.this feature is useful when doctest itself uses
Deno.test
inside the snippet, such as https://docs.deno.com/examples/mocking_tutorial/.known issues: will false-positive on
Deno.test
inside multiline comments but such cases should be rare