producer-core 0.3.3 → 0.3.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/features/registry.feature +10 -0
- data/lib/producer/core/condition.rb +3 -0
- data/lib/producer/core/env.rb +1 -0
- data/lib/producer/core/version.rb +1 -1
- data/spec/producer/core/condition_spec.rb +9 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c3bdbb4562dc3fe33ca9a8c061fe3f66024e62d3
|
4
|
+
data.tar.gz: e2c52ab359c244621fe8cd2e84aeb1dbbab4f282
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: cf04f1f9375497ec688db6bf0e74ace0b7d678805b32d14a20bb92bd743bbeab2e470f5f06052761c958c7d80326b71cca338a8a21abca457f33764549d2aef5
|
7
|
+
data.tar.gz: e561bf5bdc15b4f3603c2c3a1e6f4c51d68063b564ec937738c9980cc96f0ac40e5aeff4e58de9c182038bd2a606515028c9becc3dab849b0db4e6c5919cdb75
|
data/features/registry.feature
CHANGED
@@ -24,3 +24,13 @@ Feature: key/value registry
|
|
24
24
|
"""
|
25
25
|
When I successfully execute the recipe
|
26
26
|
Then the output must contain "some_value"
|
27
|
+
|
28
|
+
Scenario: `get' keyword fetches a value from a condition
|
29
|
+
Given a recipe with:
|
30
|
+
"""
|
31
|
+
set :some_key, 'some_value'
|
32
|
+
|
33
|
+
task(:ok) { condition { get :some_key }; echo get :some_key }
|
34
|
+
"""
|
35
|
+
When I successfully execute the recipe
|
36
|
+
Then the output must contain "some_value"
|
data/lib/producer/core/env.rb
CHANGED
@@ -173,5 +173,14 @@ module Producer::Core
|
|
173
173
|
end
|
174
174
|
end
|
175
175
|
end
|
176
|
+
|
177
|
+
describe '#get' do
|
178
|
+
let(:env) { Env.new }
|
179
|
+
|
180
|
+
it 'delegates to env registry' do
|
181
|
+
expect(env).to receive(:get).with :some_key
|
182
|
+
described_class.evaluate(env, []) { get :some_key }
|
183
|
+
end
|
184
|
+
end
|
176
185
|
end
|
177
186
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: producer-core
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Thibault Jouan
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-09-
|
11
|
+
date: 2014-09-25 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: net-ssh
|