weel 1.99.49 → 1.99.50

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (5) hide show
  1. checksums.yaml +4 -4
  2. data/Rakefile +3 -3
  3. data/lib/weel.rb +6 -3
  4. data/weel.gemspec +1 -1
  5. metadata +1 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 98fe49bc7f2c7189a00f4b602909e434163ed458
4
- data.tar.gz: afdf853993bab9c2201dbf58d41b086d706db1e4
3
+ metadata.gz: 234266663393f98240e6382ec4dc03e3497161e6
4
+ data.tar.gz: 83ba3c0d8971441f5f647fbd4cbbecd691da2f1b
5
5
  SHA512:
6
- metadata.gz: 6a7cd843b537172fd8ab319281406b176dc283ab0606117fe8283f8c0fc708d1dbe98f6176a5cc0ccbedde8964cc944ce5d5c26a138298eade20d50e3907ab1b
7
- data.tar.gz: 00a8e94a47111f7453d0851f9c662cec259d699b4f458530bfd225462fdb93a1c0465850fb077a5cc3e1e4de604c3f4219bfab8a4b9481fc4a53f8a6927463d6
6
+ metadata.gz: 5099bdd7820b8171857796d48c9d1631228f31ab5df77d8439643e36edf244ce696c026dfc48f6f54c2aafc3e631846bf36d1eff87134626d285c427d9e8dd73
7
+ data.tar.gz: 875ebe947fbdb7724525bea24d4123089db7e11746c2d8184a819783ffc9d6864f6f9cb94bbe7c536114cc584ad14e502b99fd2899962cce92732ab4a9c4e1ce
data/Rakefile CHANGED
@@ -18,8 +18,8 @@ end
18
18
 
19
19
  task :push => :gem do |r|
20
20
  `gem push pkg/weel.gem`
21
- end
21
+ end
22
22
 
23
23
  task :install => :gem do |r|
24
- `sudo gem install pkg/weel.gem`
25
- end
24
+ `gem install pkg/weel.gem`
25
+ end
data/lib/weel.rb CHANGED
@@ -447,17 +447,17 @@ class WEEL
447
447
  # searchmode is active (to find the starting position)
448
448
  def alternative(condition,args={})# {{{
449
449
  return if self.__weel_state == :stopping || self.__weel_state == :stopped || Thread.current[:nolongernecessary]
450
- hw, pos = __weel_sim_start(:alternative,args.merge(:mode => Thread.current[:alternative_mode].last, :condition => condition.is_a?(String) ? condition : nil)) if __weel_sim
450
+ hw, pos = __weel_sim_start(:alternative,args.merge(:mode => Thread.current[:alternative_mode].last, :condition => ((condition.is_a?(String) || condition.is_a?(Proc)) ? condition : nil))) if __weel_sim
451
451
  Thread.current[:mutex] ||= Mutex.new
452
452
  Thread.current[:mutex].synchronize do
453
453
  return if Thread.current[:alternative_mode][-1] == :exclusive && Thread.current[:alternative_executed][-1] == true
454
- if condition.is_a?(String) && !__weel_sim
454
+ if (condition.is_a?(String) || condition.is_a?(Proc)) && !__weel_sim
455
455
  condition = __weel_eval_condition(condition)
456
456
  end
457
457
  Thread.current[:alternative_executed][-1] = true if condition
458
458
  end
459
459
  __weel_protect_yield(&Proc.new) if __weel_is_in_search_mode || __weel_sim || condition
460
- __weel_sim_stop(:alternative,hw,pos,args.merge(:mode => Thread.current[:alternative_mode].last, :condition => condition.is_a?(String) ? condition : nil)) if __weel_sim
460
+ __weel_sim_stop(:alternative,hw,pos,args.merge(:mode => Thread.current[:alternative_mode].last, :condition => ((condition.is_a?(String) || condition.is_a?(Proc)) ? condition : nil))) if __weel_sim
461
461
  end # }}}
462
462
  def otherwise(args={}) # {{{
463
463
  return if self.__weel_state == :stopping || self.__weel_state == :stopped || Thread.current[:nolongernecessary]
@@ -515,6 +515,9 @@ class WEEL
515
515
  end
516
516
  end # }}}
517
517
 
518
+ def test(code=nil,&blk)# {{{
519
+ code || blk
520
+ end # }}}
518
521
  def pre_test(code=nil,&blk)# {{{
519
522
  [code || blk, :pre_test]
520
523
  end # }}}
data/weel.gemspec CHANGED
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = "weel"
3
- s.version = "1.99.49"
3
+ s.version = "1.99.50"
4
4
  s.platform = Gem::Platform::RUBY
5
5
  s.license = "LGPL-3.0"
6
6
  s.summary = "Preliminary release of the Workflow Execution Engine Library (WEEL)"
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: weel
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.99.49
4
+ version: 1.99.50
5
5
  platform: ruby
6
6
  authors:
7
7
  - Juergen eTM Mangler