Method: ConflowSpec::TestFlow.build
- Defined in:
- lib/conflow_spec/test_flow.rb
.build(flow_class, queue) ⇒ Class
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Creates new class which behaves like flow_class (class being tested), but with overriden logic of queueing jobs.
17 18 19 20 21 22 23 |
# File 'lib/conflow_spec/test_flow.rb', line 17 def build(flow_class, queue) Class.new(flow_class).tap do |test_class| test_class.prepend(self) test_class.name = flow_class.name test_class.queue = queue end end |