Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
heptapod
heptapod
Commits
805e03ea5173
Commit
e85e1dbb
authored
Sep 22, 2017
by
Grzegorz Bizon
Browse files
Fix hash syntax in variables collection class
parent
43534ce3f1c1
Changes
1
Hide whitespace changes
Inline
Side-by-side
spec/lib/gitlab/ci/variables/collection_spec.rb
View file @
805e03ea
...
...
@@ -3,7 +3,7 @@
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:
'SOME_VAR'
,
value:
'Some Value'
}
collection
=
described_class
.
new
([
variable
])
expect
(
collection
.
first
.
to_h
).
to
include
variable
...
...
@@ -39,7 +39,7 @@
describe
'#+'
do
it
'makes it possible to combine with an array'
do
collection
=
described_class
.
new
([{
key:
'TEST'
,
value:
1
}])
variables
=
[{
key:
'TEST'
,
value:
'something'
}]
variables
=
[{
key:
'TEST'
,
value:
'something'
}]
expect
((
collection
+
variables
).
count
).
to
eq
2
end
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment