We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent eba0925 commit db86b85Copy full SHA for db86b85
spec/workflow/dsl_spec.rb
@@ -5,6 +5,7 @@
5
require 'factor/workflow/dsl'
6
require 'factor/connector'
7
require 'factor/workflow/connector_future'
8
+require 'factor/workflow/future'
9
10
describe Factor::Workflow::DSL do
11
it 'can log' do
@@ -39,4 +40,16 @@ def initialize(options={})
39
40
expect(connector_future.action).to be_a(Sample)
41
expect(connector_future.action.test_param).to eq('foo')
42
end
43
+
44
+ it 'aggregators return a future' do
45
+ f1 = Factor::Workflow::Future.new { 1 }
46
+ f2 = Factor::Workflow::Future.new { 2 }
47
+ dsl = Factor::Workflow::DSL.new
48
49
+ expect(Factor::Workflow::Future).to receive(:any)
50
+ dsl.any(f1,f1)
51
52
+ expect(Factor::Workflow::Future).to receive(:all)
53
+ dsl.all(f1,f1)
54
+ end
55
0 commit comments