Sha256: 4ad5108929c57c0855876e7106349b2ea64c9701f34655d6e794c6c6548a9330
Contents?: true
Size: 869 Bytes
Versions: 1
Compression:
Stored size: 869 Bytes
Contents
require 'spec_helper' if Rails.version =~ /^4\./ and Capybara.javascript_driver == :selenium describe "turbolinks spec", type: :feature, js: true do it 'should invoke the API for each flash message' do visit '/test/turbolinks' click_link 'This is a turbolink' expect(page).to have_content 'Turbolink content' expect(evaluate_script('window.flashMessages')).to eq [ {'type' => 'notice', 'message' => 'Inline Notice'}, {'type' => 'notice', 'message' => 'Turbolink Notice'} ] end it 'should not duplicate messages when using the jquery.turbolinks plugin' do visit '/test/jquery_turbolinks' click_link 'This is a turbolink' click_link 'One more turbolink' expect(page).to have_content 'Turbolink content' expect(page).to have_content 'Turbolink Notice', count: 1 end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
unobtrusive_flash-3.2.0 | spec/integration/turbolinks_spec.rb |