Sha256: 703b5e4bb0373c2a1f34eafd18ea26d6ffe9c06a43832d7b714394f78d6ad01e
Contents?: true
Size: 1.06 KB
Versions: 2
Compression:
Stored size: 1.06 KB
Contents
feature 'controller methods' do describe 'redirect_back' do it 'redirects back' do visit save_path click_button 'Post to redirect_with_options' expect(current_path).to eq(save_path) end end describe 'return_to_referer' do it 'returns to saved referer' do visit clear_and_save_path click_link 'Go to save page' visit blank_path click_button 'Put to return_with_options' expect(current_path).to eq(clear_and_save_path) end it 'doesn\'t reset referer if not cleared' do visit clear_and_save_path click_link 'Go to save page' visit blank_path click_link 'Go to save page' visit blank_path click_button 'Put to return_with_options' expect(current_path).to eq(clear_and_save_path) end it 'resets referer if cleared' do visit clear_and_save_path click_link 'Go to save page' click_link 'Go to edit page' visit blank_path click_button 'Put to return_with_options' expect(current_path).to eq(save_path) end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
jump_back-0.3.2 | spec/features/controller_methods_spec.rb |
jump_back-0.3.1 | spec/features/controller_methods_spec.rb |