Sha256: 41c893055661a61f1cd01e4b0326e640efd3693bd9c5cae225b5efac17db0530

Contents?: true

Size: 854 Bytes

Versions: 5

Compression:

Stored size: 854 Bytes

Contents

require File.expand_path(__FILE__).sub(%r(/test/.*), '/test/test_helper.rb')
require File.expand_path(__FILE__).sub(%r(.*/test/), '').sub(/test_(.*)\.rb/,'\1')

require 'scout/workflow'
class TestWorkflowUsage < Test::Unit::TestCase
  module UsageWorkflow
    extend Workflow
    
    self.name = "UsageWorkflow"

    self.title = "Workflow to test documentation"
    self.description = "Use this workflow to test if the documentation is correctly presented."

    desc "Desc"
    input :array, :array, "Array"
    task :step1 => :string do
    end

    dep :step1
    desc "Desc2"
    input :float, :float, "Float"
    task :step2 => :string do
    end
  end


  def test_workflow_usage
    assert_match "test if the documentation", UsageWorkflow.usage
  end

  def test_task_usage
    assert_match "Desc2", UsageWorkflow.tasks[:step2].usage
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
scout-gear-7.3.0 test/scout/workflow/test_usage.rb
scout-gear-7.2.0 test/scout/workflow/test_usage.rb
scout-gear-7.1.0 test/scout/workflow/test_usage.rb
scout-gear-6.0.0 test/scout/workflow/test_usage.rb
scout-gear-5.2.0 test/scout/workflow/test_usage.rb