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

Add additional CLI flags to configure bun test --coverage #4346

Open
jack-weilage opened this issue Aug 26, 2023 · 1 comment · May be fixed by #12436
Open

Add additional CLI flags to configure bun test --coverage #4346

jack-weilage opened this issue Aug 26, 2023 · 1 comment · May be fixed by #12436
Labels
bun:test Something related to the `bun test` runner enhancement New feature or request

Comments

@jack-weilage
Copy link

What is the problem this feature would solve?

Bun currently has an option to configure coverage thresholds in bunfig.toml, but no way to do so from the command-line (that I can find in the documentation).

What is the feature you are proposing to solve the problem?

Bun could add CLI args similar to c8's CLI.

  • --lines [0-1]: Same as coverageThreshold = { lines = [0-1] }
  • --functions [0-100]: Same as coverageThreshold = { functions = [0-1] }
  • --all: Same as coverageThreshold = 1

What alternatives have you considered?

Continue as-is and keep bunfig.toml as a single source of truth for coverage configuration.

@jack-weilage jack-weilage added the enhancement New feature or request label Aug 26, 2023
@Electroid Electroid added the bun:test Something related to the `bun test` runner label Oct 27, 2023
@jakeboone02 jakeboone02 linked a pull request Jul 8, 2024 that will close this issue
2 tasks
@jakeboone02
Copy link
Contributor

I put up a draft PR #12436 to address this request, but it depends on #12216 being fixed first.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bun:test Something related to the `bun test` runner enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants