summaryrefslogtreecommitdiff
path: root/spec/routing
diff options
context:
space:
mode:
authorMałgorzata Ksionek <meksionek@gmail.com>2019-04-26 06:11:47 +0200
committerMałgorzata Ksionek <meksionek@gmail.com>2019-04-26 22:19:56 +0200
commitc948babf7088e26ae025c1476022699bfe9fb107 (patch)
tree7f98dddc9d8df743ba6efe883c54aeb44a1061bd /spec/routing
parent265b789476479c29ea88db174aca1d80ddf24358 (diff)
downloadgitlab-ce-c948babf7088e26ae025c1476022699bfe9fb107.tar.gz
Add specs to group routing specadd-specs-for-group-routing-spec
Diffstat (limited to 'spec/routing')
-rw-r--r--spec/routing/group_routing_spec.rb14
1 files changed, 14 insertions, 0 deletions
diff --git a/spec/routing/group_routing_spec.rb b/spec/routing/group_routing_spec.rb
index 53271550e8b..00ca394a50b 100644
--- a/spec/routing/group_routing_spec.rb
+++ b/spec/routing/group_routing_spec.rb
@@ -133,5 +133,19 @@ describe "Groups", "routing" do
let(:resource) { create(:group, parent: parent, path: 'activity') }
end
end
+
+ describe 'subgroup "boards"' do
+ it 'shows group show page' do
+ allow(Group).to receive(:find_by_full_path).with('gitlabhq/boards', any_args).and_return(true)
+
+ expect(get('/groups/gitlabhq/boards')).to route_to('groups#show', id: 'gitlabhq/boards')
+ end
+
+ it 'shows boards index page' do
+ allow(Group).to receive(:find_by_full_path).with('gitlabhq', any_args).and_return(true)
+
+ expect(get('/groups/gitlabhq/-/boards')).to route_to('groups/boards#index', group_id: 'gitlabhq')
+ end
+ end
end
end