karma-runner / karma-ng-scenario

A Karma plugin. Adapter for Angular's Scenario Runner.
MIT License
25 stars 16 forks source link

Error: "adapter.js does not match any file" using ng-scenario #14

Open clakech opened 10 years ago

clakech commented 10 years ago

Hi,

I face a strange error when I try to launch my e2e test with angular ng-scenario framework using grunt-karma:

First I see a WARN in console: WARN [watcher]: Pattern "/Users/foobar/foo/node_modules/karma-ng-scenario/lib/adapter.js" does not match any file.

Then an error: Aborted due to warnings.

I see in the code that karma try to load adapter.js for lib directory but this file is never commit because it is excluded in .gitignore.

Here is an abstract of my karma grunt config:

{
  "name": "foo",
  "version": "1.8.2",
  "dependencies": {},
  "devDependencies": {
    "grunt": "~0.4.1",
    "grunt-karma": "0.7.1",
    "karma": "0.10.8",
    "karma-coverage": "0.1.0",
    "karma-junit-reporter": "~0.1.0",
    "karma-jasmine": "~0.1",
    "karma-chrome-launcher": "~0.1",
    "karma-ng-scenario": "~0.1",
    "karma-ng-html2js-preprocessor": "~0.1",
    "karma-sauce-launcher": "~0.1"
  },
  "engines": {
    "node": ">=0.8.0"
  }
}

Here is the full error stack

Running "karma:e2e" (karma) task WARN [config]: urlRoot normalized to "/k/" INFO [karma]: Karma v0.10.8 server started at http://localhost:8081/k/ INFO [launcher]: Starting browser Chrome WARN [watcher]: Pattern "/Users/foobar/foo/node_modules/karma-ng-scenario/lib/adapter.js" does not match any file. INFO [Chrome 33.0.1750 (Mac OS X 10.9.2)]: Connected on socket 7ZEWG5S0lrJeOlvjEe4Z Chrome 33.0.1750 (Mac OS X 10.9.2): Executed 0 of 0 ERROR (0.315 secs / 0 secs) Warning: Task "karma:e2e" failed. Use --force to continue.

Aborted due to warnings.

Please, could you have a look into this. This would help us.

Regards,

clakech commented 10 years ago

to solve this issue I fork this and then commit adapter.js into lib directory: https://github.com/webadeo/karma-ng-scenario/tree/fix

now my build work but I would prefer to understand why you don't commit lib/adapter.js for client using karma-ng-scenario as dependency in their own project.