Sha256: 13cc5d134fe9004ab73e4d3cb55d78078e1154a3ba44fd7aa78dd5ee19f5f32b

Contents?: true

Size: 732 Bytes

Versions: 9

Compression:

Stored size: 732 Bytes

Contents

describe 'Update the site theme', type: :feature do
  let(:exhibit) { FactoryBot.create(:exhibit) }
  let(:user) { FactoryBot.create(:exhibit_admin, exhibit: exhibit) }

  before { login_as user }

  it 'updates the exhibit theme' do
    visit spotlight.edit_exhibit_appearance_path(exhibit)

    expect(page).to have_content('Visual theme')
    choose 'Modern'

    click_button 'Save changes'

    expect(page).to have_content('The exhibit was successfully updated.')

    within '#sidebar' do
      click_link 'Appearance'
    end

    click_link 'Exhibit masthead'

    expect(page).to have_checked_field 'Modern'
    expect(page).to have_xpath('//link[contains(@href, "/assets/application_modern")]', visible: false)
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
blacklight-spotlight-2.4.1 spec/features/exhibit_themes_spec.rb
blacklight-spotlight-2.4.0 spec/features/exhibit_themes_spec.rb
blacklight-spotlight-2.3.3 spec/features/exhibit_themes_spec.rb
blacklight-spotlight-2.3.2 spec/features/exhibit_themes_spec.rb
blacklight-spotlight-2.3.1 spec/features/exhibit_themes_spec.rb
blacklight-spotlight-2.3.0 spec/features/exhibit_themes_spec.rb
blacklight-spotlight-2.2.1 spec/features/exhibit_themes_spec.rb
blacklight-spotlight-2.2.0 spec/features/exhibit_themes_spec.rb
blacklight-spotlight-2.1.0 spec/features/exhibit_themes_spec.rb