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

Feature: Option to fail run on empty test suite #216

Open
stanislavgeorgiev opened this issue Sep 19, 2018 · 0 comments
Open

Feature: Option to fail run on empty test suite #216

stanislavgeorgiev opened this issue Sep 19, 2018 · 0 comments

Comments

@stanislavgeorgiev
Copy link

Expected behaviour

I have 20 files with tests and each of those files has its describe() section and at least one it() section. In Angular when a new component is create a test file is created automatically with a single boiler plate test to check whether the component is creating successfully. Sometimes a team member may be enticed to comment a failing test so they can deliver the code and to keep the build green.

I would like to have an option in karma.config.js to fail/show error when there's a single test suite that has a describe() block but doesn't have any it() blocks. There's already a similar option failOnEmptyTestSuite but that one is if there are no tests at all so perhaps it could be extended to cover this case too or add another option.

Actual behaviour

It would skip the entire empty test suite

Environment Details

  • Karma version: 3.0.0
  • Jasmine: 2.99.1
  • Angular 6.1.1

Steps to reproduce the behaviour

  1. Have a couple of test files with Jasmine tests in them.
  2. Add another test file with only a describe() block and no it() blocks
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

No branches or pull requests

1 participant