【发布时间】:2014-05-25 13:00:11
【问题描述】:
我的测试套件:
describe 'test loading page', ->
tester = undefined
beforeEach ->
if tester then tester.destroy
tester = ngMidwayTester 'angularjsGettingStartedApp'
it "should defined dubFuntion and evaluate directive", (done) ->
tester.visit '/superman' , () ->
expect(1).toEqual(2)
done()
结果
Chrome 34.0.1847 (Linux): Executed 0 of 1 SUCCESS (0 secs / 0 secs)
Chrome 34.0.1847 (Linux): Executed 0 of 1 SUCCESS (0 secs / 0 secs)
Chrome 34.0.1847 (Linux): Executed 1 of 1 SUCCESS (0.182 secs / 0.166 secs)
PhantomJS 1.9.7 (Linux): Executed 1 of 1 SUCCESS (0.046 secs / 0.183 secs)
TOTAL: 2 SUCCESS
无论我尝试什么,它总是返回 SUCCESS - 似乎由于某种原因没有调用访问回调??? , 我用:
"angular": "1.2.15",
"grunt-karma": "^0.8.3",
"karma-chrome-launcher": "^0.1.3",
"karma-jasmine": "^0.1.5",
"karma-ng-scenario": "^0.1.0",
"karma-phantomjs-launcher": "^0.1.4",
【问题讨论】:
标签: angularjs unit-testing coffeescript