diff options
author | Michael Kozono <mkozono@gmail.com> | 2017-09-06 21:31:45 +0300 |
---|---|---|
committer | Michael Kozono <mkozono@gmail.com> | 2017-09-06 22:07:21 +0300 |
commit | 1feeea9c6af5d683f18c021df16e4eedfa9306e0 (patch) | |
tree | 4869cd4d3b9e839a4eba612c9da5205b73dafbe6 /spec/views/groups | |
parent | a887194abd2ea0c0cbcd24f0ff7630800d3eec12 (diff) |
Refer to “Share with group lock” consistently
Diffstat (limited to 'spec/views/groups')
-rw-r--r-- | spec/views/groups/edit.html.haml_spec.rb | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/spec/views/groups/edit.html.haml_spec.rb b/spec/views/groups/edit.html.haml_spec.rb index 86bb28a43c1..38cfb84f0d5 100644 --- a/spec/views/groups/edit.html.haml_spec.rb +++ b/spec/views/groups/edit.html.haml_spec.rb @@ -3,7 +3,7 @@ require 'spec_helper' describe 'groups/edit.html.haml' do include Devise::Test::ControllerHelpers - describe 'Share lock option' do + describe '"Share with group lock" setting' do let(:root_owner) { create(:user) } let(:root_group) { create(:group) } @@ -11,7 +11,7 @@ describe 'groups/edit.html.haml' do root_group.add_owner(root_owner) end - shared_examples_for 'share lock option' do |checkbox_options| + shared_examples_for '"Share with group lock" setting' do |checkbox_options| it 'should have the correct label, help text, and checkbox options' do assign(:group, test_group) allow(view).to receive(:can?).with(test_user, :admin_group, test_group).and_return(true) @@ -32,7 +32,7 @@ describe 'groups/edit.html.haml' do let(:test_group) { root_group } let(:test_user) { root_owner } - it_behaves_like 'share lock option', { disabled: false, checked: false } + it_behaves_like '"Share with group lock" setting', { disabled: false, checked: false } end context 'for a subgroup', :nested_groups do @@ -40,22 +40,22 @@ describe 'groups/edit.html.haml' do let(:sub_owner) { create(:user) } let(:test_group) { subgroup } - context 'when the root_group has "Share lock" disabled' do - context 'when the subgroup has "Share lock" disabled' do + context 'when the root_group has "Share with group lock" disabled' do + context 'when the subgroup has "Share with group lock" disabled' do context 'as the root_owner' do let(:test_user) { root_owner } - it_behaves_like 'share lock option', { disabled: false, checked: false } + it_behaves_like '"Share with group lock" setting', { disabled: false, checked: false } end context 'as the sub_owner' do let(:test_user) { sub_owner } - it_behaves_like 'share lock option', { disabled: false, checked: false } + it_behaves_like '"Share with group lock" setting', { disabled: false, checked: false } end end - context 'when the subgroup has "Share lock" enabled' do + context 'when the subgroup has "Share with group lock" enabled' do before do subgroup.update_column(:share_with_group_lock, true) end @@ -63,37 +63,37 @@ describe 'groups/edit.html.haml' do context 'as the root_owner' do let(:test_user) { root_owner } - it_behaves_like 'share lock option', { disabled: false, checked: true } + it_behaves_like '"Share with group lock" setting', { disabled: false, checked: true } end context 'as the sub_owner' do let(:test_user) { sub_owner } - it_behaves_like 'share lock option', { disabled: false, checked: true } + it_behaves_like '"Share with group lock" setting', { disabled: false, checked: true } end end end - context 'when the root_group has "Share lock" enabled' do + context 'when the root_group has "Share with group lock" enabled' do before do root_group.update_column(:share_with_group_lock, true) end - context 'when the subgroup has "Share lock" disabled (parent overridden)' do + context 'when the subgroup has "Share with group lock" disabled (parent overridden)' do context 'as the root_owner' do let(:test_user) { root_owner } - it_behaves_like 'share lock option', { disabled: false, checked: false } + it_behaves_like '"Share with group lock" setting', { disabled: false, checked: false } end context 'as the sub_owner' do let(:test_user) { sub_owner } - it_behaves_like 'share lock option', { disabled: false, checked: false } + it_behaves_like '"Share with group lock" setting', { disabled: false, checked: false } end end - context 'when the subgroup has "Share lock" enabled (same as parent)' do + context 'when the subgroup has "Share with group lock" enabled (same as parent)' do before do subgroup.update_column(:share_with_group_lock, true) end @@ -101,13 +101,13 @@ describe 'groups/edit.html.haml' do context 'as the root_owner' do let(:test_user) { root_owner } - it_behaves_like 'share lock option', { disabled: false, checked: true } + it_behaves_like '"Share with group lock" setting', { disabled: false, checked: true } end context 'as the sub_owner' do let(:test_user) { sub_owner } - it_behaves_like 'share lock option', { disabled: true, checked: true } + it_behaves_like '"Share with group lock" setting', { disabled: true, checked: true } end end end |