我有以下测试。由于某种原因,@$e
我在 before 函数中设置的在测试中未定义:
assert = buster.assert
buster.testCase 'BaseChart',
before: ->
@el = sinon.spy()
@$el = [@el]
console.log(@$el)
##[LOG] [function spy() {}]
'updates when the model changed': ->
console.log(@$el)
##[LOG] undefined