-
Notifications
You must be signed in to change notification settings - Fork 417
Add missing unit tests which cover package individually scenario. #268
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
Add missing unit tests which cover package individually scenario. #268
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Many thanks for adding the tests. Coverage did a big jump now!
If you could change the length check I commented, it's good to go ;-)
tests/validate.test.js
Outdated
globSyncStub.callsFake(filename => [_.replace(filename, '*', 'js')]); | ||
return expect(module.validate()).to.be.fulfilled | ||
.then(() => { | ||
expect(module.webpackConfig.length).to.equal(4); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could be expressed as expect(module.webpackConfig).to.have.lengthOf(4);
which will implicitly check for an array like structure.
@ceilfors Just recognized that this breaks the unit tests on Windows (because of the fixed |
Committed and fixed |
@HyperBrain Apologies! Maybe it's a good idea to add Windows to travis? |
@ceilfors Yes, I planned to add AppVeyor as second build machine for the unit tests |
Add missing unit tests which cover package individually scenario.
What did you implement:
When trying to help on #266, I discovered that the plugin has 0% coverage at the moment for
service.package.individually
option in validate.js. This PR adds more unit tests for the missing coverage.How did you implement it:
Unit tests are written.
How can we verify it:
Clone branch, run the test.
Todos:
Is this ready for review?: YES
Is it a breaking change?: NO