Sha256: b410cb4001f19cc348ed9921f09e53cd5262cb463d550d8483b55bf1c394ab3e

Contents?: true

Size: 413 Bytes

Versions: 4

Compression:

Stored size: 413 Bytes

Contents

# frozen_string_literal: true

$LOAD_PATH.unshift(File.expand_path("../../lib", __dir__))
require "dev_suite"

# Create a workflow with parallel tasks
engine = DevSuite::Workflow::Engine.new

parallel_step = DevSuite::Workflow.create_parallel_step("Parallel Task") do |context|
  [
    ->(ctx) { puts "Task 1 executed" },
    ->(ctx) { puts "Task 2 executed" },
  ]
end

engine.step(parallel_step)
engine.execute

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
dev_suite-0.2.13 examples/workflow/parallel_workflow.rb
dev_suite-0.2.12 examples/workflow/parallel_workflow.rb
dev_suite-0.2.11 examples/workflow/parallel_workflow.rb
dev_suite-0.2.10 examples/workflow/parallel_workflow.rb