You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
What is the current behavior?
When jasmine configuration set the property failSpecWithNoExpectations to true (since v.3.5.0) and karma-parallel add extra tests explained in documentation:
Why are there extra tests in my output?
If this plugin discovers that you have focused some tests (fit, it.only, etc...) in other browser instances, it will add an extra focused test in the current browser instance to limit the running of the tests in the given browser. Similarly, when dividing up the tests, if there are not enough tests for a given browser, it will add an extra test to prevent karma from failing due to no running tests.__
The result: has failed tests.
If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem
Set in karma.conf.js a jasmine configuration like:
client: {
jasmine: {
failSpecWithNoExpectations: true
},
clearContext: false
},
Submitted a PR to add expect().nothing(); in default specs added by karma-parallel.
Alternatively, to resolve this issue, we can add a minimal test that would be run on every executor instance. This will lead to karma-parallel not adding its own spec(without any assertions) for execution and the test will pass
**I'm submitting a ... **
What is the current behavior?
When jasmine configuration set the property failSpecWithNoExpectations to true (since v.3.5.0) and karma-parallel add extra tests explained in documentation:
Why are there extra tests in my output?
If this plugin discovers that you have focused some tests (fit, it.only, etc...) in other browser instances, it will add an extra focused test in the current browser instance to limit the running of the tests in the given browser. Similarly, when dividing up the tests, if there are not enough tests for a given browser, it will add an extra test to prevent karma from failing due to no running tests.__
The result: has failed tests.
client: {
jasmine: {
failSpecWithNoExpectations: true
},
clearContext: false
},
parallelOptions: {
executors: 4, // Defaults to cpu-count - 1
shardStrategy: 'description-length'
},
4,. Execute tests (like 'ng test')
What is the expected behavior?
Expect that pass the tests in all executors.
Please tell us about your environment:
Used Latest Version of karma-parallel 0.3.1
Jasmine version: ^3.8.0
Browser: Chrome
Language: Angular 12.2.0
May be add into the extra tests "expect().nothing()"?
Thanks in advance
The text was updated successfully, but these errors were encountered: