question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Changes in 3.1.0 break custom karma-jasmine-html-reporter spec filtering

See original GitHub issue

As the latest version does a strict equality comparison, the filtering with suite name does not work anymore.

I am try to filter a suite from browser using the url http://localhost:9876/debug.html?spec=MySuite or by clicking the generated suite link (same url). It results in following error.

adapter.js:344 Uncaught Error: No spec found with name: "MySuite"
    at getSpecsByName (adapter.js:344)
    at getDebugSpecToRun (adapter.js:354)
    at getSpecsToRun (adapter.js:429)
    at new KarmaSpecFilter (adapter.js:435)
    at createSpecFilter (adapter.js:452)
    at ContextKarma.start (adapter.js:479)
    at ContextKarma.window.__karma__.loaded (debug.js:27)
    at debug.html?spec=MySuite:53

Ideally, the generated links should work.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:3
  • Comments:20 (8 by maintainers)

github_iconTop GitHub Comments

4reactions
nicojscommented, Apr 23, 2020

What’s the reason for setting the specFilter at that stage in the process?

Well to be sure the reason is simple: no test fails when I made that change.

@johnjbarton that’s fair. Would you be willing to accept a PR that places the code back in adapter.js and adds a test for a spec filter override?

Thanks for the awesome work maintaining Karma. It’s a very important development tool. ❤

3reactions
tscislocommented, Feb 2, 2020

I reverted back to “karma-jasmine”: “~3.0.3” and all works fine in WebStorm Please fix the newest version as well.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Changelog - Karma test runner
Breaking Changes #. runnerPort is merged with port if you are using karma run with custom --runer-port , please change that to --port...
Read more >
while resolving: karma-jasmine-html-reporter@1.7.0 npm err ...
This warning says that your package karma-jasmine-html-reporter has peer dependency to jasmine version >=3. Basically if you install latest version of jasmine ...
Read more >
karma-jasmine-html-reporter - npm
A Karma plugin. Dynamically displays tests results at debug.html page. Latest version: 2.0.0, last published: 7 months ago.
Read more >
node_modules/karma/CHANGELOG.md · master
BREAKING CHANGES. Karma plugins which rely on the fact that Karma uses Bluebird promises may break as Bluebird-specific API is no longer ...
Read more >
Diff - 085b489add939e1dcdd2b7e048a6c40671e982cc^!
Revert your changes to `jasmine.js` and `jasmine-html.js` - * We do ... addReporter(htmlReporter); - - /** - * Filter which specs will be ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found