Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobert Speicher <rspeicher@gmail.com>2015-06-05 20:57:01 +0300
committerRobert Speicher <rspeicher@gmail.com>2015-06-14 00:58:16 +0300
commit0c0c31ff34b3010c2c269ec56ef48dd305c6f74a (patch)
treebc9bfe8512f3a7abc694f77bdd4824ed7d80b3de /spec/features/profiles
parent44d68159999a0ee30f7714470c1ef5b0c4a717fa (diff)
Move the "Design" templates and logic to Preferences
Diffstat (limited to 'spec/features/profiles')
-rw-r--r--spec/features/profiles/preferences_spec.rb33
1 files changed, 33 insertions, 0 deletions
diff --git a/spec/features/profiles/preferences_spec.rb b/spec/features/profiles/preferences_spec.rb
new file mode 100644
index 00000000000..0e033652a9c
--- /dev/null
+++ b/spec/features/profiles/preferences_spec.rb
@@ -0,0 +1,33 @@
+require 'spec_helper'
+
+describe 'Profile > Preferences' do
+ let(:user) { create(:user) }
+
+ before do
+ login_as(user)
+ end
+
+ describe 'User changes their application theme', js: true do
+ let(:default_class) { Gitlab::Theme.css_class_by_id(nil) }
+ let(:theme_5_class) { Gitlab::Theme.css_class_by_id(5) }
+
+ before do
+ visit profile_preferences_path
+ end
+
+ it 'changes immediately' do
+ expect(page).to have_selector("body.#{default.css_class}")
+
+ choose "user_theme_id_#{theme.id}"
+
+ expect(page).not_to have_selector("body.#{default.css_class}")
+ expect(page).to have_selector("body.#{theme.css_class}")
+ end
+ end
+
+ describe 'User changes their syntax highlighting theme' do
+ before do
+ visit profile_preferences_path
+ end
+ end
+end