PhantomJS和Karma Jasmine测试Linux错误

时间:2014-07-16 17:49:31

标签: continuous-integration phantomjs karma-runner karma-jasmine

我的Karma测试有问题。我像往常一样运行它们:

node_modules/karma/bin/karma start test/karma.conf.coffee

然后我得到了:

INFO [karma]: Karma v0.9.8 server started at http://localhost:9876/
INFO [launcher]: Starting browser PhantomJS
INFO [PhantomJS 1.9.7 (Mac OS X)]: Connected on socket id sdxrDmAhioK5PjzAMy1O
PhantomJS 1.9.7 (Mac OS X) ERROR               
        Script error.
PhantomJS 1.9.7 (Mac OS X) ERROR               
        Script error.
PhantomJS 1.9.7 (Mac OS X) ERROR               
        Script error.

和Ubuntu:

INFO [karma]: Karma v0.9.8 server started at http://localhost:9876/
INFO [launcher]: Starting browser PhantomJS
INFO [PhantomJS 1.9.7 (Linux)]: Connected on socket id kTXPYWO4-nCqsKK8Pb5m
PhantomJS 1.9.7 (Linux) ERROR
  Script error.
PhantomJS 1.9.7 (Linux) ERROR
  Script error.

最有趣的是,在Mac上我几乎总是得到

PhantomJS 1.9.7 (Mac OS X): Executed 185 of 185 SUCCESS (3.242 secs / 2.381 secs)

在Linux上,它在开发环境中看起来很相似。不幸的是,当我在CI上运行测试(codeship.io)时,测试总是失败。它最近才发生,因为当我进行150次测试时,一切都很顺利。

我做错了什么?我可以为PhantomJS设置某种超时吗?

0 个答案:

没有答案