Comments (8)
same here...
from karma-parallel.
After adding some debug info, I see the following flow:
onRunStart
onBrowserStart
onBrowserStart
onBrowserStart
onBrowserStart
onBrowserStart
onBrowserStart
onRunStart
Reporter : undefined total undefined passed undefined failed undefined skipped
onRunComplete
onBrowserStart
onBrowserStart
onBrowserStart
onBrowserStart
onBrowserStart
onBrowserStart
from karma-parallel.
@ben8p Thanks for the contribution!
I'm trying to understand karma's lifecycle a bit better. Perhaps I am missing something or perhaps karma is a little inconsistent with itself: It appears this is the lifecycle of events for a karma reporter
x = number of browsers
y = number of tests
1
onRunStart (this is where I initialize that object)x
onBrowserStarty
onSpecCompletex
onBrowserComplete1
onRunComplete (this is where I clear that object)
If watching / using TDD, I would expect that if I change a file, I would start over at onRunStart
, not starting with onBrowserStart
. But if your fix does indeed fix this issue, then perhaps karma is not very consistent by not calling onRunStart for sequential runs.
What do you think?
from karma-parallel.
Well,
I have the feeling it has to do with a file changed between step 1 and step 2.
When I look at Nyan cat reporter I see it restart multiple times (and all aborted instance are saying "undefined" instead of the number of tests.
There's probably a sort of life cycle optimization built in karma...
As far as I tested the fix has not side effects...
from karma-parallel.
@joeljeske will you consider merging the PR ? Do you need more inputs ?
from karma-parallel.
I am running into this issue as well. @joeljeske Can this PR be merged (assuming it fixes the issue) ?
from karma-parallel.
@abeymg maybe you can try the modified code locally and confirm it also fixes the issue you're having?
It is only one single line to change.
from karma-parallel.
@joeljeske @ben8p I did that and can confirm that it fixed the issue for me.
from karma-parallel.
Related Issues (20)
- karma-parallel do not return exit code 1 anymore on too low code coverage HOT 7
- Exception when using "karma run" HOT 7
- Should fail the test cases split to a browser that is disconnected HOT 4
- Aggregated Log Output HOT 10
- No support for Circle CI HOT 2
- Support Karma 4 HOT 1
- When browser disconnects, remaining tests are skipped HOT 5
- Random failures with uncaught errors and missing tests
- Jasmine test timeout is ignored HOT 1
- Random test failures during CI process
- How to enable running tests in parallel on CI
- Publish new version HOT 2
- No calculation of all passed tests on kubernetis -job
- Script Error while executing karma tests HOT 1
- Only supporting Jasmine ?
- Karma parallel cannot find any tests after starting Chrome
- Need help to get code coverage HOT 3
- `Parallel` throws away global beforeEach in multi-browser mode
- Is there a way to let what files to run in what threads/browser instances ?
- failSpecWithNoExpectations to true in jasmine and karma-parallel add the extra tests HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from karma-parallel.