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
{{ message }}
Repository navigation
ember-test never terminates with COVERAGE=true #81
ember-cli: 2.10.0 ( also repro in previous version )
ember: 2.10.0
ember-cli-code-coverage: 0.38.0
ember t everything is good with no errors and proper termination. COVERAGE=true ember t everything succeeds and the coverage is generated as expected, but the process never terminates. When I run it in DEBUG="*" mode it seems to hang with:
engine:ws writing "3" +0ms
engine:ws received "2" +25s
engine:socket packet +0ms
engine:socket got ping +0ms
engine:socket sending packet "pong" (undefined) +0ms
engine:socket flushing buffer to transport +0ms
engine:ws writing "3" +0ms
engine:ws received "2" +25s
engine:socket packet +0ms
engine:socket got ping +0ms
engine:socket sending packet "pong" (undefined) +0ms
engine:socket flushing buffer to transport +0ms
engine:ws writing "3" +0ms
engine:ws received "2" +25s
engine:socket packet +0ms
engine:socket got ping +0ms
engine:socket sending packet "pong" (undefined) +0ms
engine:socket flushing buffer to transport +0ms
engine:ws writing "3" +0ms
Looked into debugging phantom js but found no obvious errors.
I noticed that the request.onload callback never got called. This might be caused by pretenderjs (even though the request was made and I had a passthrough rule in mirage/config.js).
In my codebase in tests/helpers/destroy-app.js there was a missing line server.shutdown();.
I opened this ticket over a month before 88.
Anyways, the hanging issue is fixed for me after upgrading to 0.3.10 ( and previously having applied topaxi's fix ).
Was still seeing this in 0.3.10. I'm using mostly default generated tests with ember 2.10 and ember-cli-mirage. It must have been a problem with a mirage instance never getting shutdown and hanging around. Resolved it by adding if(server !== undefined) { server.shutdown(); } to beforeEach and afterEach in each acceptance test file. As in,
I had the same problem. Because of Integration tests where I use New Testing API.
I had to close mirage server (server.shutdown()) after every Integration tests. Here is quite neat solution for folks that will strugle with this in the future:
Activity
topaxi commentedon Nov 30, 2016
My builds stopped working with the same behaviour, it seemed to appear randomly. I guess this might be a dependency issue?
rox163 commentedon Nov 30, 2016
I've seen this as well but only with addons that have acceptance tests. If I skip the acceptance test then the run completes and reports coverage.
lone-cloud commentedon Nov 30, 2016
@rox163 Thank you! That was causing the freezing for me too.
topaxi commentedon Dec 2, 2016
Are you by any chance using
ember-cli-mirage?I noticed that the
request.onloadcallback never got called. This might be caused by pretenderjs (even though the request was made and I had a passthrough rule inmirage/config.js).In my codebase in
tests/helpers/destroy-app.jsthere was a missing lineserver.shutdown();.Here the full file which solved the issue for me:
tests/helpers/destroy-app.jslone-cloud commentedon Dec 2, 2016
That was exactly my problem too. Thank you. 😲
mdarmetko commentedon Dec 24, 2016
Still having this issue with version 0.3.9 even with the above solution. Reverting to 0.2.2 fixed it for me.
lone-cloud commentedon Dec 27, 2016
The issue is back for me with 0.3.9 but 0.3.8 is still good
kategengler commentedon Jan 5, 2017
Hopefully solved by #87
kategengler commentedon Jan 5, 2017
#87 has been released in 0.3.10
ming-codes commentedon Jan 7, 2017
Duplicates with #88?
lone-cloud commentedon Jan 10, 2017
I opened this ticket over a month before 88.
Anyways, the hanging issue is fixed for me after upgrading to 0.3.10 ( and previously having applied topaxi's fix ).
mdarmetko commentedon Jan 10, 2017
Was still seeing this in 0.3.10. I'm using mostly default generated tests with ember 2.10 and ember-cli-mirage. It must have been a problem with a mirage instance never getting shutdown and hanging around. Resolved it by adding
if(server !== undefined) { server.shutdown(); }to beforeEach and afterEach in each acceptance test file. As in,Hope this helps someone else having the same problem.
isaacaskew commentedon Dec 27, 2017
@topaxi - that mirage
server.shutdown()trick saved my ass. If you're ever in the Chicago area, your drink's on me.tniezurawski commentedon Jun 19, 2018
I had the same problem. Because of Integration tests where I use New Testing API.
I had to close mirage server (
server.shutdown()) after every Integration tests. Here is quite neat solution for folks that will strugle with this in the future:https://gist.github.com/tniezurawski/907d0fa83a7a621146add3871d1827ca