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

feat(bench): add --no-run flag #18433

Merged
merged 4 commits into from
Mar 26, 2023
Merged

feat(bench): add --no-run flag #18433

merged 4 commits into from
Mar 26, 2023

Conversation

GJZwiers
Copy link
Contributor

@GJZwiers GJZwiers commented Mar 25, 2023

This PR adds a flag to deno bench to cache and type-check specifiers only, similar to deno test --no-run

Closes #18429

This PR adds a flag to `deno bench` to type-check specifiers only similar to `deno test --no-run`
Copy link
Collaborator

@aapoalas aapoalas left a comment

Choose a reason for hiding this comment

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

Nice feature addition, thank you very much for doing this and in such short a time! I left a minor issue to use the test to verify that the code in general isn't run.

@@ -0,0 +1 @@
const _value: string = 1;
Copy link
Collaborator

Choose a reason for hiding this comment

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

Maybe add a console.log to the file to confirm that the code is not run at all, and not just that the benchmark calls themselves are not run.

Copy link
Collaborator

@aapoalas aapoalas left a comment

Choose a reason for hiding this comment

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

Looks good to me. Lint failed from lines that didn't change from previous... I wonder how that happens?

@GJZwiers
Copy link
Contributor Author

Is it a breaking change in clap v4?

Copy link
Member

@crowlKats crowlKats left a comment

Choose a reason for hiding this comment

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

clap v4 had a few changes:

cli/args/flags.rs Outdated Show resolved Hide resolved
cli/args/flags.rs Outdated Show resolved Hide resolved
@aapoalas aapoalas enabled auto-merge (squash) March 26, 2023 14:31
@aapoalas aapoalas merged commit a29d88b into denoland:main Mar 26, 2023
@GJZwiers GJZwiers deleted the bench_add_no_run_flag branch March 26, 2023 15:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add flag deno bench --no-run
3 participants