diff options
-rw-r--r-- | test/puppettest.rb | 2 | ||||
-rwxr-xr-x | test/test | 3 |
2 files changed, 4 insertions, 1 deletions
diff --git a/test/puppettest.rb b/test/puppettest.rb index e2c620bb8..0bd7d80c5 100644 --- a/test/puppettest.rb +++ b/test/puppettest.rb @@ -41,7 +41,7 @@ module TestPuppet @@tmpfiles = [@configpath, tmpdir()] @@tmppids = [] - if $0 =~ /.+\.rb/ + if $0 =~ /.+\.rb/ or Puppet[:debug] Puppet[:logdest] = :console Puppet[:loglevel] = :debug $VERBOSE = 1 @@ -15,6 +15,7 @@ require 'getoptlong' #[ "--size", "-s", GetoptLong::REQUIRED_ARGUMENT ], result = GetoptLong.new( + [ "--debug", "-d", GetoptLong::NO_ARGUMENT ], [ "--help", "-h", GetoptLong::NO_ARGUMENT ] ) @@ -22,6 +23,8 @@ usage = "USAGE: %s [--help] <testsuite> <testsuite> .." % $0 result.each { |opt,arg| case opt + when "--debug" + Puppet[:debug] = true when "--help" puts usage exit |