Sha256: 1d94bf4e5a6d1c1a9b1dce58eeda80ed52b67f919c4350377f9eef6e7ace47d0

Contents?: true

Size: 1017 Bytes

Versions: 9

Compression:

Stored size: 1017 Bytes

Contents

# This spec fails on sauce randomly, disable for now
if ENV['BROWSER'] && ENV['BROWSER'] != 'sauce'
  require 'spec_helper'

  describe 'flash messages', type: :feature, :sauce => true do
    it 'should flash on sucesses, notices, warnings, and errors' do
      visit '/'

      click_link 'Flash'

      click_link 'Flash Notice'
      expect(page).to have_content('A notice message')
      find('.alert').click
      expect(page).to_not have_content('A notice message')

      click_link 'Flash Success'
      expect(page).to have_content('A success message')
      find('.alert').click
      expect(page).to_not have_content('A success message')

      click_link 'Flash Warning'
      expect(page).to have_content('A warning message')
      find('.alert').click
      expect(page).to_not have_content('A warning message')

      click_link 'Flash Error'
      expect(page).to have_content('An error message')
      find('.alert').click
      expect(page).to_not have_content('An error message')

    end
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
volt-0.8.27.beta2 spec/integration/flash_spec.rb
volt-0.8.27.beta1 spec/integration/flash_spec.rb
volt-0.8.26.beta1 spec/integration/flash_spec.rb
volt-0.8.26 spec/integration/flash_spec.rb
volt-0.8.24 spec/integration/flash_spec.rb
volt-0.8.23 spec/integration/flash_spec.rb
volt-0.8.22 spec/integration/flash_spec.rb
volt-0.8.22.beta2 spec/integration/flash_spec.rb
volt-0.8.22.beta1 spec/integration/flash_spec.rb