nathanboktae / mocha-phantomjs

:coffee: :ghost: Run client-side mocha tests in the command line through phantomjs
MIT License
954 stars 112 forks source link

Not reporting number of passes/fails after certain number of tests #228

Closed explorer2309 closed 8 years ago

explorer2309 commented 8 years ago

We have an application with about 1400 tests. The CI server reads the summary output of the tests (TAP report) to determine whether all tests have passed or not. This has been working fine for months.

However, now when I add any more test, the output does not include the summary. And so the CI server assumes tests have failed.

I have tried changing --reporter to various other options, but none of them seems to output the summary any more.

I have also tried changing timeout to a very large number, and that does not fix the problem either.

Note: The version of mocha-phantomjs is 4.0.2

Please let me know if you have any ideas.

nathanboktae commented 8 years ago

It could be many things. Your test could be in an infinite loop. Your CI system could be killing the process after so much time.

I really can't help you when you say you have this huge complex system and of the many components you think it's one specific component without further investigation.

explorer2309 commented 8 years ago

There is another point I forgot to mention - when I run the tests in browser (using mocha.run) it works fine. The stats on top of the html update fine. The problem appears only with running tests using command line - mochaPhantomJS.run()

I can safely say that there is no infinite loop, because commenting out any random test seems to get it working.

Also, the CI system killing is not a problem because I get the same problem when running it from command line.

I will be looking to possibly debug this. Any pointers in that direction will be very helpful.

Thanks!

nathanboktae commented 8 years ago

Please reopen if you find the root cause to be in mocha-phantomjs (and not phantomjs, your CI system, your tests, etc)