1

I'm getting the following error when running the entire suite of tests:

timeout of 2000ms exceeded. Ensure the done() callback is being called in this test.

I found this super useful response on StackOverflow In mocha testing while calling asynchronous function how to avoid the timeout Error: timeout of 2000ms exceeded. and here #278

However, the problem still persists even after deleting every occurrence in my tests that deal with HTTP and promises. All I've got now are Angular directive and controller specs which doesn't seem to do much other than checking template data, directive and controller logic.

Here's what I currently have in package.json, upgrading libraries such as mocha and karma-mocha didn't seem help either.

"devDependencies": {
  "karma": "~0.12.30",
  "karma-chai-jquery": "~1.0.0",
  "karma-chrome-launcher": "~0.1",
  "karma-coffee-preprocessor": "~0.1.3",
  "karma-firefox-launcher": "~0.1",
  "karma-jquery": "~0.1.0",
  "karma-mocha": "0.2.0",
  "karma-sinon-chai": "~0.1.1",
  "karma-spec-reporter": "~0.0.10",
  "mocha": "^2.2.5"
}

Does anyone know why this is still happening and if there's a better way to know exactly what the issue is? thanks!

Community
  • 1
  • 1
Gustavo Matias
  • 3,508
  • 3
  • 27
  • 30

0 Answers0