Sha256: 7b1881e92c1225b17ffe65db2ea8271374039377e2b1a576898c5868e5c202e2

Contents?: true

Size: 930 Bytes

Versions: 55

Compression:

Stored size: 930 Bytes

Contents

module Support
  class DummyDynflowAction < Dynflow::Action
  end

  class DummyPauseAction < Actions::EntryAction
    def plan
      plan_action(DummyPauseActionWithCustomTroubleshooting)
      plan_self
    end

    def run
      error! "This is an error"
    end
  end

  class DummyPauseActionWithCustomTroubleshooting < Actions::EntryAction
    def run
      error! "This is an error"
    end

    def troubleshooting_info
      ForemanTasks::TroubleshootingHelpGenerator::Info.new.tap do |i|
        i.add_line _('This task requires special handling.')
        i.add_link(ForemanTasks::TroubleshootingHelpGenerator::Link.new(
                     name: :custom_link,
                     title: _('custom link'),
                     href: "/additional_troubleshooting_page",
                     description: _("Investigate %{link} on more details for this custom error.")
                   ))
      end
    end
  end
end

Version data entries

55 entries across 55 versions & 1 rubygems

Version Path
foreman-tasks-0.17.1 test/support/dummy_dynflow_action.rb
foreman-tasks-0.15.11 test/support/dummy_dynflow_action.rb
foreman-tasks-0.16.2 test/support/dummy_dynflow_action.rb
foreman-tasks-0.15.10 test/support/dummy_dynflow_action.rb
foreman-tasks-0.16.1 test/support/dummy_dynflow_action.rb
foreman-tasks-0.17.0 test/support/dummy_dynflow_action.rb
foreman-tasks-0.15.9 test/support/dummy_dynflow_action.rb
foreman-tasks-0.15.8 test/support/dummy_dynflow_action.rb
foreman-tasks-0.15.7 test/support/dummy_dynflow_action.rb
foreman-tasks-0.16.0 test/support/dummy_dynflow_action.rb
foreman-tasks-0.15.6 test/support/dummy_dynflow_action.rb
foreman-tasks-0.15.5 test/support/dummy_dynflow_action.rb
foreman-tasks-0.15.4 test/support/dummy_dynflow_action.rb
foreman-tasks-0.15.3 test/support/dummy_dynflow_action.rb
foreman-tasks-0.15.2 test/support/dummy_dynflow_action.rb