class Onceover::CLI::Run

Public Class Methods

command() click to toggle source
# File lib/onceover/cli/run.rb, line 12
      def self.command
        @command ||= Cri::Command.define do
          name 'run'
          usage 'run [spec|acceptance]'
          summary 'Runs either the spec or acceptance tests'
          description <<-DESCRIPTION
This will run the full set of spec or acceptance tests.
This includes deploying using r10k and running all custom tests.
          DESCRIPTION

          optional :t,  :tags,             'A list of tags. Only tests with these tags will be run'
          optional :c,  :classes,          'A list of classes. Only tests with these classes will be run'
          optional :n,  :nodes,            'A list of nodes. Only tests with these nodes will be run'
          optional :s,  :skip_r10k,        'Skip the r10k step'
          optional :f,  :force,            'Passes --force to r10k, overwriting modules'
          optional :sv, :strict_variables, 'Run with strict_variables set to yes'

          run do |opts, args, cmd|
            puts cmd.help(:verbose => opts[:verbose])
            exit 0
          end
        end
      end