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:
authorGrzegorz Bizon <grzesiek.bizon@gmail.com>2018-03-12 15:58:54 +0300
committerGrzegorz Bizon <grzesiek.bizon@gmail.com>2018-03-12 15:58:54 +0300
commit5ed8286e742597720d48e3bf6fc56938ba717f5e (patch)
treeef52db059c2d04ce620c0871fa41809b0b074b23 /spec/lib/gitlab/ci/variables/collection_spec.rb
parent9d4c9272e016442cd84fbada82493b03b350bb8e (diff)
Extract variables collection item to a separate class
Diffstat (limited to 'spec/lib/gitlab/ci/variables/collection_spec.rb')
-rw-r--r--spec/lib/gitlab/ci/variables/collection_spec.rb5
1 files changed, 3 insertions, 2 deletions
diff --git a/spec/lib/gitlab/ci/variables/collection_spec.rb b/spec/lib/gitlab/ci/variables/collection_spec.rb
index 16c23ae450a..c4b2df7dede 100644
--- a/spec/lib/gitlab/ci/variables/collection_spec.rb
+++ b/spec/lib/gitlab/ci/variables/collection_spec.rb
@@ -3,10 +3,11 @@ require 'spec_helper'
describe Gitlab::Ci::Variables::Collection do
describe '.new' do
it 'can be initialized with an array' do
- variable = { key: 'SOME_VAR', value: 'Some Value' }
+ variable = { key: 'VAR', value: 'value', public: true }
+
collection = described_class.new([variable])
- expect(collection.first.to_h).to include variable
+ expect(collection.first.to_hash).to eq variable
end
it 'can be initialized without an argument' do