Sha256: 54d9644e6d36b461158058df64da13f4a504f439a2939fca6bcc0ea88fb65950

Contents?: true

Size: 858 Bytes

Versions: 116

Compression:

Stored size: 858 Bytes

Contents

# frozen_string_literal: true

require 'eac_cli/definition'
require 'eac_cli/runner/class_runner'

module EacCli
  module Runner
    module AfterClassMethods
      # @return [EacCli::Runner::ClassRunner]
      def class_runner(runner_context_args)
        ::EacCli::Runner::ClassRunner.new(self, runner_context_args)
      end

      def create(*runner_context_args)
        class_runner(runner_context_args).create
      end

      def run(*runner_context_args)
        class_runner(runner_context_args).run
      end

      def runner_definition(&block)
        @runner_definition ||= super_runner_definition
        @runner_definition.instance_eval(&block) if block
        @runner_definition
      end

      def super_runner_definition
        superclass.try(:runner_definition).if_present(&:dup) || ::EacCli::Definition.new
      end
    end
  end
end

Version data entries

116 entries across 116 versions & 3 rubygems

Version Path
eac_cli-0.34.1 lib/eac_cli/runner/after_class_methods.rb
eac_cli-0.34.0 lib/eac_cli/runner/after_class_methods.rb
eac_tools-0.66.0 sub/eac_cli/lib/eac_cli/runner/after_class_methods.rb
eac_tools-0.65.1 sub/eac_cli/lib/eac_cli/runner/after_class_methods.rb
eac_tools-0.65.0 sub/eac_cli/lib/eac_cli/runner/after_class_methods.rb
eac_cli-0.33.0 lib/eac_cli/runner/after_class_methods.rb
eac_tools-0.64.0 sub/eac_cli/lib/eac_cli/runner/after_class_methods.rb
eac_cli-0.32.0 lib/eac_cli/runner/after_class_methods.rb
eac_tools-0.63.0 sub/eac_cli/lib/eac_cli/runner/after_class_methods.rb
eac_tools-0.62.1 sub/eac_cli/lib/eac_cli/runner/after_class_methods.rb
eac_cli-0.31.0 lib/eac_cli/runner/after_class_methods.rb
eac_tools-0.62.0 sub/eac_cli/lib/eac_cli/runner/after_class_methods.rb
eac_tools-0.61.1 sub/eac_cli/lib/eac_cli/runner/after_class_methods.rb
eac_tools-0.61.0 sub/eac_cli/lib/eac_cli/runner/after_class_methods.rb
eac_tools-0.60.3 sub/eac_cli/lib/eac_cli/runner/after_class_methods.rb
eac_tools-0.60.2 sub/eac_cli/lib/eac_cli/runner/after_class_methods.rb
eac_tools-0.60.1 sub/eac_cli/lib/eac_cli/runner/after_class_methods.rb
eac_tools-0.60.0 sub/eac_cli/lib/eac_cli/runner/after_class_methods.rb
eac_tools-0.59.0 sub/eac_cli/lib/eac_cli/runner/after_class_methods.rb
eac_tools-0.58.0 sub/eac_cli/lib/eac_cli/runner/after_class_methods.rb