In addition to the accepted answer, which in any case is a much better framework for tests, I found a reproducible script for this: the beforeEach sections nested in beforeEach cause Karma to stop any further Jasmine tests. You can see in the question that this is true - beforeEach for beforeEach is inside the external beforeEach .
As part of the merge, one of our beforeEach lines that loads the module under test was accidentally moved to a later beforeEach . This prevented all tests from running after that. Karma reported that x of y tests were performed, where x was 65 less than y, but that the test run was successful and was not skipped.
Therefore, if you encounter this, check the report output for the last “successfully” completed test (I say “successfully” in quotation marks, since it probably caused the problem), and look, there is no beforeEach in it beforeEach nested.
source share