cascadence 0.4.4 → 0.4.5

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 04c26bca2741dbf5fa943285f82ebb719b3a1d5b
4
- data.tar.gz: d095ded07ffac12d8a6d0acbe6b757ab4d19242e
3
+ metadata.gz: eede3d2479289e867b8a8c92cae6ac8c0f741336
4
+ data.tar.gz: 3cb88d2d3edbf685896b2fc7b6adb8903a570481
5
5
  SHA512:
6
- metadata.gz: edb4e6d22e1ee2d3c58c52711572ae90d0de42b974f74cffc79012c600c80865aca274aa385a8bf571b3c81a324abed0c05e62bf34afa0566e5016ad71c96c9b
7
- data.tar.gz: bc1b92863af80dd96e623d6303a1de9581081c1e82c416edd575ae72e2edcc52f4ef9c595f93420d321137484ba518cd529280cedbea61c221a0ae38a4951fc4
6
+ metadata.gz: f65986116510d9ab7379674920882d2a6562e3461b22259ae5c03546f6208f279235f104242f40c04de5ae212c8030d7e59bf20022c2cd47b9e2ec4f7f796acd
7
+ data.tar.gz: bade220954e6a531a76955e5b0d0233622ea19bce5be6edeb8aa72d1352835778beb199e7922c4be7a42f555e50eac09b31ad1f9937df689d95219c53fbddcc2
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.4.4
1
+ 0.4.5
data/cascadence.gemspec CHANGED
@@ -5,11 +5,11 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = "cascadence"
8
- s.version = "0.4.4"
8
+ s.version = "0.4.5"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Thomas Chen"]
12
- s.date = "2013-05-10"
12
+ s.date = "2013-05-15"
13
13
  s.description = "Organizational helper for writing serializations for use with threading. The biggest use case of this would be in selenium / capybara based integration testing as this allows you to run flows in parallel."
14
14
  s.email = "foxnewsnetwork@gmail.com"
15
15
  s.executables = ["cascadence"]
@@ -46,9 +46,13 @@ module Cascadence
46
46
  end
47
47
 
48
48
  def _run_sequential(tasks)
49
- while task = tasks.next
50
- task.call
49
+ begin
50
+ while task = tasks.next
51
+ task.call
52
+ end
53
+ rescue StopIteration => e
54
+ puts "Done with all your tasks, master"
51
55
  end
52
56
  end
53
57
  end
54
- end
58
+ end
@@ -71,7 +71,7 @@ module Cascadence
71
71
  def _consider_rescuing(e)
72
72
  raise e if _my_rescuers.nil?
73
73
  raise e if _my_rescuers[e.class].nil?
74
- send _my_rescuers[e.class]
74
+ send _my_rescuers[e.class], e
75
75
  end
76
76
 
77
77
  def _cascadence_end?
@@ -95,4 +95,4 @@ module Cascadence
95
95
  end
96
96
  end
97
97
 
98
- end
98
+ end
@@ -33,7 +33,7 @@ describe Cascadence::ClassMethods do
33
33
  end
34
34
 
35
35
  private
36
- def _white_knight
36
+ def _white_knight(e)
37
37
  self.state += ". But then some white knight (say Ryan Gosling or Ryan Reynolds) comes along, "
38
38
  self.state += " saves her and they live happily ever after"
39
39
  end
@@ -68,7 +68,7 @@ describe Cascadence::ClassMethods do
68
68
  end
69
69
 
70
70
  private
71
- def _white_knight
71
+ def _white_knight(e)
72
72
  self.state += ". But then some white knight (say Ryan Gosling or Ryan Reynolds) comes along, "
73
73
  self.state += "and she too happily abandons her responsibilities and runs off with this guy."
74
74
  self.state += "The queen is bitterly disappointed, decides to turn the country into a democracy."
@@ -9,12 +9,12 @@ describe Cascadence::Commander do
9
9
 
10
10
  context "flow -p" do
11
11
  it "should run the flow stated" do
12
- expect {@thorify.call @argv}.to raise_error StopIteration
12
+ @thorify.call @argv
13
13
  end
14
14
  end
15
15
  context "flow -t 2 -p" do
16
16
  it "should run the flow twice" do
17
- expect {@thorify.call @argv}.to raise_error StopIteration
17
+ @thorify.call @argv
18
18
  end
19
19
  end
20
20
  context "flow -f -p" do
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cascadence
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.4
4
+ version: 0.4.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Thomas Chen
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-05-10 00:00:00.000000000 Z
11
+ date: 2013-05-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: thor