我正在尝试使用 save_and_open_page 查看 rspec 测试失败的详细信息:
相关测试代码
it { should have_selector('div.alert'); save_and_open_page}
测试执行并失败,但现在生成输出
相关的 Gemfile 片段:
group :test do
gem 'capybara', '1.1.2'
gem 'factory_girl_rails', '4.1.0'
gem 'launchy'
end
Launchy 安装正常:
$ bundle show launchy
//.rvm/gems/ruby-1.9.3-p286/gems/launchy-2.1.2
相关的 config/test.rb 片段(我期待 save_and_open_page 输出到达这里)
Capybara.save_and_open_page_path = 'tmp/test_out'
任何想法为什么输出不显示?