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:
authorGitLab Bot <gitlab-bot@gitlab.com>2020-01-27 18:08:51 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2020-01-27 18:08:51 +0300
commit1ea1db491c8bc90789acda45c9002aaa5c4dc498 (patch)
tree46d974fed38f2ea63e69bad9d43760c62611c958 /spec/lib/gitlab/gl_repository_spec.rb
parent22e9af3c8b8aedf7f46b786be968862b74a2d07e (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/lib/gitlab/gl_repository_spec.rb')
-rw-r--r--spec/lib/gitlab/gl_repository_spec.rb8
1 files changed, 6 insertions, 2 deletions
diff --git a/spec/lib/gitlab/gl_repository_spec.rb b/spec/lib/gitlab/gl_repository_spec.rb
index 3290bef8aa5..3cfc4c2a132 100644
--- a/spec/lib/gitlab/gl_repository_spec.rb
+++ b/spec/lib/gitlab/gl_repository_spec.rb
@@ -4,7 +4,7 @@ require 'spec_helper'
describe ::Gitlab::GlRepository do
describe '.parse' do
- set(:project) { create(:project, :repository) }
+ let_it_be(:project) { create(:project, :repository) }
it 'parses a project gl_repository' do
expect(described_class.parse("project-#{project.id}")).to eq([project, Gitlab::GlRepository::PROJECT])
@@ -14,8 +14,12 @@ describe ::Gitlab::GlRepository do
expect(described_class.parse("wiki-#{project.id}")).to eq([project, Gitlab::GlRepository::WIKI])
end
- it 'throws an argument error on an invalid gl_repository' do
+ it 'throws an argument error on an invalid gl_repository type' do
expect { described_class.parse("badformat-#{project.id}") }.to raise_error(ArgumentError)
end
+
+ it 'throws an argument error on an invalid gl_repository id' do
+ expect { described_class.parse("project-foo") }.to raise_error(ArgumentError)
+ end
end
end