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:
Diffstat (limited to 'spec/requests/git_http_spec.rb')
-rw-r--r--spec/requests/git_http_spec.rb10
1 files changed, 10 insertions, 0 deletions
diff --git a/spec/requests/git_http_spec.rb b/spec/requests/git_http_spec.rb
index 38c8d43376e..05b16119a0e 100644
--- a/spec/requests/git_http_spec.rb
+++ b/spec/requests/git_http_spec.rb
@@ -245,6 +245,16 @@ RSpec.describe 'Git HTTP requests' do
end
end
+ context 'when project name is missing' do
+ let(:path) { "/#{user.namespace.path}/info/refs" }
+
+ it 'does not redirect to the incorrect path' do
+ get path
+
+ expect(response).not_to redirect_to("/#{user.namespace.path}.git/info/refs")
+ end
+ end
+
it_behaves_like 'project path without .git suffix' do
let(:repository_path) { "#{user.namespace.path}/project.git-project" }
end