Commit 9db74f5b authored by Dylan Griffith's avatar Dylan Griffith

Merge branch '211887-dedupe-gl-repository-specs' into 'master'

De-duplicate GlRepository EE specs

See merge request gitlab-org/gitlab!27952
parents cdf6a458 86b17f77
......@@ -213,7 +213,6 @@ Gitlab/DuplicateSpecLocation:
- ee/spec/services/merge_requests/update_service_spec.rb
- ee/spec/services/system_hooks_service_spec.rb
- ee/spec/helpers/ee/auth_helper_spec.rb
- ee/spec/lib/ee/gitlab/gl_repository_spec.rb
- ee/spec/models/ee/namespace_spec.rb
- ee/spec/models/ee/note_spec.rb
- ee/spec/serializers/ee/environment_entity_spec.rb
......
# frozen_string_literal: true
require 'spec_helper'
describe ::EE::Gitlab::GlRepository do
describe Gitlab::GlRepository do
describe "DESIGN" do
it "uses the design access checker" do
expect(described_class::DESIGN.access_checker_class).to eq(::Gitlab::GitAccessDesign)
......@@ -12,4 +12,20 @@ describe ::EE::Gitlab::GlRepository do
.to be_a(::DesignManagement::Repository)
end
end
describe '.parse' do
let_it_be(:project) { create(:project, :repository) }
it 'parses a design gl_repository' do
expect(described_class.parse("design-#{project.id}")).to eq([project, project, EE::Gitlab::GlRepository::DESIGN])
end
end
describe '.types' do
it 'contains both the EE and CE repository types' do
expected_types = Gitlab::GlRepository::TYPES.merge(EE::Gitlab::GlRepository::EE_TYPES)
expect(described_class.types).to eq(expected_types)
end
end
end
# frozen_string_literal: true
require 'spec_helper'
describe Gitlab::GlRepository do
describe '.parse' do
let_it_be(:project) { create(:project, :repository) }
it 'parses a design gl_repository' do
expect(described_class.parse("design-#{project.id}")).to eq([project, project, EE::Gitlab::GlRepository::DESIGN])
end
end
describe '.types' do
it 'contains both the EE and CE repository types' do
expected_types = Gitlab::GlRepository::TYPES.merge(EE::Gitlab::GlRepository::EE_TYPES)
expect(described_class.types).to eq(expected_types)
end
end
end
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment