debian-mirror-gitlab/spec/lib/gitlab/dependency_linker_spec.rb

112 lines
2.6 KiB
Ruby
Raw Normal View History

2019-10-12 21:52:04 +05:30
# frozen_string_literal: true
2019-12-04 20:38:33 +05:30
require 'spec_helper'
2017-09-10 17:25:29 +05:30
describe Gitlab::DependencyLinker do
describe '.link' do
it 'links using GemfileLinker' do
blob_name = 'Gemfile'
expect(described_class::GemfileLinker).to receive(:link)
described_class.link(blob_name, nil, nil)
end
it 'links using GemspecLinker' do
blob_name = 'gitlab_git.gemspec'
expect(described_class::GemspecLinker).to receive(:link)
described_class.link(blob_name, nil, nil)
end
it 'links using PackageJsonLinker' do
blob_name = 'package.json'
expect(described_class::PackageJsonLinker).to receive(:link)
described_class.link(blob_name, nil, nil)
end
it 'links using ComposerJsonLinker' do
blob_name = 'composer.json'
expect(described_class::ComposerJsonLinker).to receive(:link)
described_class.link(blob_name, nil, nil)
end
it 'links using PodfileLinker' do
blob_name = 'Podfile'
expect(described_class::PodfileLinker).to receive(:link)
described_class.link(blob_name, nil, nil)
end
it 'links using PodspecLinker' do
blob_name = 'Reachability.podspec'
expect(described_class::PodspecLinker).to receive(:link)
described_class.link(blob_name, nil, nil)
end
it 'links using PodspecJsonLinker' do
blob_name = 'AFNetworking.podspec.json'
expect(described_class::PodspecJsonLinker).to receive(:link)
described_class.link(blob_name, nil, nil)
end
it 'links using CartfileLinker' do
blob_name = 'Cartfile'
expect(described_class::CartfileLinker).to receive(:link)
described_class.link(blob_name, nil, nil)
end
it 'links using GodepsJsonLinker' do
blob_name = 'Godeps.json'
expect(described_class::GodepsJsonLinker).to receive(:link)
described_class.link(blob_name, nil, nil)
end
it 'links using RequirementsTxtLinker' do
blob_name = 'requirements.txt'
expect(described_class::RequirementsTxtLinker).to receive(:link)
described_class.link(blob_name, nil, nil)
end
2020-03-13 15:44:24 +05:30
it 'links using CargoTomlLinker' do
blob_name = 'Cargo.toml'
expect(described_class::CargoTomlLinker).to receive(:link)
described_class.link(blob_name, nil, nil)
end
2020-06-23 00:09:42 +05:30
it 'links using GoModLinker' do
blob_name = 'go.mod'
expect(described_class::GoModLinker).to receive(:link)
described_class.link(blob_name, nil, nil)
end
it 'links using GoSumLinker' do
blob_name = 'go.sum'
expect(described_class::GoSumLinker).to receive(:link)
described_class.link(blob_name, nil, nil)
end
2017-09-10 17:25:29 +05:30
end
end