Sha256: ab282d48b8fc6ffa8d1d3e44540989bcaf04514f888d8c2f94a857bdc8199fb1

Contents?: true

Size: 713 Bytes

Versions: 2

Compression:

Stored size: 713 Bytes

Contents

# frozen_string_literal: true

module Specimen
  module Command
    class ExecRunner < TestRunner
      class_option :profile, aliases: %w[-p], type: :string

      no_commands do
        def perform
          super

          run_profile_check!
          check_config_not_nil!
          inside runtime.work_dir do
            run(exec_cmd)
          end
        end

        def tests_path
          ''
        end

        def run_profile_check!
          raise "Missing command option '--profile|-p'" unless profile?
        end

        def framework
          profile_config['framework'] || nil
        end

        def profile_name
          profile? ? profile : nil
        end
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
specimen-0.0.3.alpha lib/specimen/command/runner/exec_runner.rb
specimen-0.0.2.alpha lib/specimen/command/runner/exec_runner.rb