summaryrefslogtreecommitdiff
path: root/spec/features/profiles/user_search_settings_spec.rb
blob: 60df0d7532b245f0a376cccb0cbffa7a4ec472e8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
# frozen_string_literal: true

require 'spec_helper'

RSpec.describe 'User searches their settings', :js do
  let_it_be(:user) { create(:user) }

  before do
    sign_in(user)
  end

  context 'in profile page' do
    let(:visit_path) { profile_path }

    it_behaves_like 'can search settings with feature flag check', 'Public Avatar', 'Main settings'
  end

  context 'in preferences page' do
    before do
      visit profile_preferences_path
    end

    it_behaves_like 'can search settings', 'Syntax highlighting theme', 'Behavior'
  end
end