Sha256: 16b07fc2a122677d7e15c9e54101c2de93d2d5eec0da47470b0a3946b5d2652c

Contents?: true

Size: 792 Bytes

Versions: 2

Compression:

Stored size: 792 Bytes

Contents

# frozen_string_literal: true

require 'eac_ruby_utils/console/docopt_runner'
require 'eac_ruby_utils/core_ext'

module Avm
  module Tools
    class Runner
      class AppSrc
        class Test < ::EacRubyUtils::Console::DocoptRunner
          include ::EacCli::DefaultRunner

          runner_definition do
            desc 'Test local project.'
          end

          def run
            context(:instance_banner)
            infov 'Test command', test_command
            if test_command.present?
              test_command.system!
            else
              fatal_error 'No test command found'
            end
          end

          def test_command
            context(:instance).configuration.if_present(&:any_test_command)
          end
        end
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
avm-tools-0.97.0 lib/avm/tools/runner/app_src/test.rb
avm-tools-0.96.0 lib/avm/tools/runner/app_src/test.rb