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

Fails silently if only reporter is missing #2141

Closed
foxyblocks opened this issue May 17, 2016 · 3 comments
Closed

Fails silently if only reporter is missing #2141

foxyblocks opened this issue May 17, 2016 · 3 comments

Comments

@foxyblocks
Copy link

Expected behavior

If the plugin is missing for the only configured reporter (e.g. karma-mocha-reporter), karma should exit with an error status.

Actual behavior

It does not run any tests and gives no failure. Only a log warning:

17 05 2016 13:28:27.831:WARN [reporter]: Can not load "mocha", it is not registered!
  Perhaps you are missing some plugin?
17 05 2016 13:28:27.851:WARN [karma]: No captured browser, open http://localhost:9876/
17 05 2016 13:28:27.857:INFO [karma]: Karma v0.13.22 server started at http://localhost:9876/

Enviroment Details

  • Karma version: 0.13.22
module.exports = function(config) {
  config.set({
    frameworks: ['jasmine'],
    reporters: ['mocha'],
    files: ['tests/**/*']
    //...
  });
};

Steps to reproduce the behaviour

  1. Create simple project set reporter to ['mocha'], but do not install the plugin for that reporter
  2. karma start
@hpurmann
Copy link
Contributor

I can reproduce this. It fails with

30 06 2016 17:34:11.356:ERROR [reporter]: Can not load reporter "mocha", it is not registered!
  Perhaps you are missing some plugin?
30 06 2016 17:34:12.782:INFO [karma]: Karma v1.1.0 server started at http://localhost:9876/
30 06 2016 17:34:12.782:INFO [launcher]: Launching browser Firefox with unlimited concurrency
30 06 2016 17:34:12.783:ERROR [karma]: Found 1 load error

but the exit code is 0.

@benwill
Copy link

benwill commented Aug 9, 2016

Running into same issue

@johnjbarton
Copy link
Contributor

Based on reading the current code this bug should have been fixed. Please reopen if you see it again.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants