Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

karma-chai-plugins missing from package.json => failing gulp test:client #2219

Copy link
Copy link
Closed
@erikrenberg

Description

@erikrenberg
Issue body actions
  • I understand that GitHub issues are not for tech support, but for questions specific to this generator, bug reports, and feature requests.
Item Version
generator-angular-fullstack 4.0.4
Node 6.5.0
npm 3.10.7

Windows 10
Client Tests

I generated a fresh app with "mocha": false and I noticed that gulp test:client fails because of a missing npm package:

{ Error: Cannot find module 'karma-chai-plugins'

And indeed that file is required by the generated karma.conf.js, but is not included in the likewise generated package.json.

The template file for package.json seems to only include that package if mocha is enabled, which again I didn't select when running the generator.

So either I made some strange combination of choices :), or karma-chai-plugins should be added by the generator not just when mocha is selected?

PS. I also noticed that two require('karma-chai-plugins') seems to be added by the generator if "mocha":true. See lines 50 and 56 in templates/app/karma.conf.js. This doesn't seem right either. DS.

Here is a potentially relevant part of my .yo-rc.json:

    "jasmine": true,
      "mocha": false,
      "should": false,
      "expect": false

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions

    Morty Proxy This is a proxified and sanitized view of the page, visit original site.