1
当我运行集成测试与水豚/ WebKit的我收到此错误信息:水豚的错误信息,测试仍然通过
undefined|36|TypeError: Result of expression 'node' [undefined] is not an object.
但是它不会导致测试失败,它不会总是发生。当它(最后断言前右)发生似乎在测试同一时刻发生
测试:
it "does something with things" do
#....
within('#dialog_box') do
click_button 'Save'
end
puts 'after within'
page.should have_content(thing_attrs[:name])
puts 'after assertion'
end
最终输出:
after within
undefined|36|TypeError: Result of expression 'node' [undefined] is not an object.
after assertion
does something with things [pass]
我怎样才能缩小这是什么原因造成的?它使测试输出丑陋:)
看起来非常相似:http://stackoverflow.com/questions/11849683/capybara-webkit-error-in-rspec – 2012-08-08 23:48:44