summaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
authorDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2017-01-24 17:32:34 +0200
committerDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2017-02-07 15:37:36 +0200
commitf39dbf3d3d4d5c99910043e8793a96246f0039fe (patch)
tree3c57925c524cb0a21ee189e352e8b46e356229bc /spec
parentda359c46b598ba44cff1829ab4abe49c4c225ae2 (diff)
downloadgitlab-ce-f39dbf3d3d4d5c99910043e8793a96246f0039fe.tar.gz
Allow creating nested group via UIdz-create-nested-groups-via-ui
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
Diffstat (limited to 'spec')
-rw-r--r--spec/features/groups_spec.rb19
1 files changed, 18 insertions, 1 deletions
diff --git a/spec/features/groups_spec.rb b/spec/features/groups_spec.rb
index a515c92db37..37b7c20239f 100644
--- a/spec/features/groups_spec.rb
+++ b/spec/features/groups_spec.rb
@@ -45,6 +45,23 @@ feature 'Group', feature: true do
end
end
+ describe 'create a nested group' do
+ let(:group) { create(:group, path: 'foo') }
+
+ before do
+ visit subgroups_group_path(group)
+ click_link 'New Subgroup'
+ end
+
+ it 'creates a nested group' do
+ fill_in 'Group path', with: 'bar'
+ click_button 'Create group'
+
+ expect(current_path).to eq(group_path('foo/bar'))
+ expect(page).to have_content("Group 'bar' was successfully created.")
+ end
+ end
+
describe 'group edit' do
let(:group) { create(:group) }
let(:path) { edit_group_path(group) }
@@ -117,7 +134,7 @@ feature 'Group', feature: true do
visit path
click_link 'Subgroups'
- expect(page).to have_content(nested_group.full_name)
+ expect(page).to have_content(nested_group.name)
end
end
end