atp 0.5.0 → 0.5.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 56626a1f7ba78ee3873728c72bc7a8cd59a133a9
4
- data.tar.gz: 12daab882fdeb97053df85297ba999d873d7be9c
3
+ metadata.gz: f62f7363f60de549fcdd62079d15f1a2a15d1080
4
+ data.tar.gz: f8c1f9056501a2df6d68726081a2d6a214150e77
5
5
  SHA512:
6
- metadata.gz: ac147bd76ea5f0e7a6a37cec31ac4991127f785de57c18bc30fb7219c7759ca2e0cb67d7d97d0f32d137e12e4be92cd8b9c8babd5aa3e023989507034f986a71
7
- data.tar.gz: 57b65dcd2e9473142443bbb230b50b4b9b49b8b74dfec85e240a5d762d47980a46d393cd86b2c4eb65c16f2e142eb98bf71009df2ed90fe9b84259009d7a83fa
6
+ metadata.gz: ecb5cc42b0edf32d97e331a98ec302f145e98e48eddf292161916c79ee00e8bfc0b50c3e8eadbed7868fc326aed95c83e1ea63cbbc83036f0ef74dd1622197cd
7
+ data.tar.gz: b5efe45ab648a39ce0e785fff92d11203aee8f351907f5ae4ecd9aacd6c7b02e4dcc9ecd67b9746900cee8d23cf96443549f4ac04d3785405a48de7c83f85273
data/config/version.rb CHANGED
@@ -1,7 +1,7 @@
1
1
  module ATP
2
2
  MAJOR = 0
3
3
  MINOR = 5
4
- BUGFIX = 0
4
+ BUGFIX = 3
5
5
  DEV = nil
6
6
 
7
7
  VERSION = [MAJOR, MINOR, BUGFIX].join(".") + (DEV ? ".pre#{DEV}" : '')
@@ -230,7 +230,10 @@ module ATP
230
230
  def on_fail(options = {})
231
231
  children = []
232
232
  if options[:bin] || options[:softbin]
233
- children << set_result(:fail, bin: options[:bin], softbin: options[:softbin], bin_description: options[:bin_description])
233
+ fail_opts = { bin: options[:bin], softbin: options[:softbin] }
234
+ fail_opts[:bin_description] = options[:bin_description] if options[:bin_description]
235
+ fail_opts[:softbin_description] = options[:softbin_description] if options[:softbin_description]
236
+ children << set_result(:fail, fail_opts)
234
237
  end
235
238
  if options[:set_run_flag] || options[:set_flag]
236
239
  children << set_run_flag(options[:set_run_flag] || options[:set_flag])
@@ -243,7 +246,10 @@ module ATP
243
246
  def on_pass(options = {})
244
247
  children = []
245
248
  if options[:bin] || options[:softbin]
246
- children << set_result(:pass, bin: options[:bin], softbin: options[:softbin], bin_description: options[:bin_description])
249
+ pass_opts = { bin: options[:bin], softbin: options[:softbin] }
250
+ pass_opts[:bin_description] = options[:bin_description] if options[:bin_description]
251
+ pass_opts[:softbin_description] = options[:softbin_description] if options[:softbin_description]
252
+ children << set_result(:pass, pass_opts)
247
253
  end
248
254
  if options[:set_run_flag] || options[:set_flag]
249
255
  children << set_run_flag(options[:set_run_flag] || options[:set_flag])
@@ -256,9 +262,16 @@ module ATP
256
262
  def set_result(type, options = {})
257
263
  children = []
258
264
  children << type
259
- children << n(:bin, options[:bin]) if options[:bin]
260
- children << n(:softbin, options[:softbin]) if options[:softbin]
261
- children << n(:bin_description, options[:bin_description]) if options[:bin_description]
265
+ if options[:bin] && options[:bin_description]
266
+ children << n(:bin, options[:bin], options[:bin_description])
267
+ else
268
+ children << n(:bin, options[:bin]) if options[:bin]
269
+ end
270
+ if options[:softbin] && options[:softbin_description]
271
+ children << n(:softbin, options[:softbin], options[:softbin_description])
272
+ else
273
+ children << n(:softbin, options[:softbin]) if options[:softbin]
274
+ end
262
275
  result = n(:set_result, *children)
263
276
 
264
277
  if options[:conditions]
data/lib/atp/flow.rb CHANGED
@@ -74,10 +74,18 @@ module ATP
74
74
  options[:on_fail] ||= {}
75
75
  options[:on_fail][:bin] = b
76
76
  end
77
+ if b = options.delete(:bin_description)
78
+ options[:on_fail] ||= {}
79
+ options[:on_fail][:bin_description] = b
80
+ end
77
81
  if b = options.delete(:softbin) || b = options.delete(:sbin) || b = options.delete(:soft_bin)
78
82
  options[:on_fail] ||= {}
79
83
  options[:on_fail][:softbin] = b
80
84
  end
85
+ if b = options.delete(:softbin_description) || options.delete(:sbin_description) || options.delete(:soft_bin_description)
86
+ options[:on_fail] ||= {}
87
+ options[:on_fail][:softbin_description] = b
88
+ end
81
89
  if options.delete(:continue)
82
90
  options[:on_fail] ||= {}
83
91
  options[:on_fail][:continue] = true
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: atp
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.0
4
+ version: 0.5.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Stephen McGinty
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-02-09 00:00:00.000000000 Z
11
+ date: 2017-02-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: origen