Error: You need to include some adapter that implements __karma__.start method

后端 未结 26 1365
梦谈多话
梦谈多话 2020-12-01 11:53

I\'m trying to add some unit tests to one of my projects.

So far I\'ve installed and configured karma, and have installed jasmine. I\'ve one test file in my te

26条回答
  •  一生所求
    2020-12-01 12:16

    I've been struggling with this too. What I came up to is that this error occurs because one of the following reasons

    • No test adapter installed or defined (frameworks property in karma.conf.js
    • No karma configuration found (ie, no karma.conf.js in current dir or no config file specified in command)

    My problem was that my config file was named karma.config.js instead of karma.conf.js.

    If you've installed the test adapter but it still doesn't work, try running karma init and go through the guided config setup.

提交回复
热议问题