summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--test/puppettest.rb2
-rwxr-xr-xtest/test3
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
diff --git a/test/test b/test/test
index acea0fa25..8c2ad55d6 100755
--- a/test/test
+++ b/test/test
@@ -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