Skip to content
Snippets Groups Projects
Commit a6260b1e authored by Grzegorz Bizon's avatar Grzegorz Bizon
Browse files

Remove code that removes duplicate CI variables

At this point this is being handled by GitLab Runner and we need to
introduce this as a separate merge request.
parent 9a74b92d
No related branches found
No related tags found
No related merge requests found
Loading
@@ -147,8 +147,7 @@ module Ci
Loading
@@ -147,8 +147,7 @@ module Ci
end end
   
def variables def variables
(predefined_variables + yaml_variables + project_variables + trigger_variables) predefined_variables + yaml_variables + project_variables + trigger_variables
.reverse.uniq { |var| var[:key] }.reverse
end end
   
def merge_request def merge_request
Loading
Loading
Loading
@@ -253,19 +253,6 @@ describe Ci::Build, models: true do
Loading
@@ -253,19 +253,6 @@ describe Ci::Build, models: true do
) )
end end
end end
context 'when job variable has same key other variable has' do
let(:build) { create(:ci_build, name: 'production') }
it 'contains job yaml variable' do
expect(subject).to include(key: :DB_NAME, value: 'mysql',
public: true)
end
it 'contains only one variable with this key' do
expect(subject.count { |var| var[:key] == :DB_NAME } ).to eq 1
end
end
end end
end end
end end
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment