summaryrefslogtreecommitdiff
path: root/worker/tests/https.rb
diff options
context:
space:
mode:
authorSteve Kemp <steve@steve.org.uk>2012-11-13 14:33:12 +0000
committerSteve Kemp <steve@steve.org.uk>2012-11-13 14:33:12 +0000
commite51fd8e44f54c284bd2c6355bbc3443f4c20a952 (patch)
tree5e5e884bd368e5ddc2a081de5ce002be2ed05225 /worker/tests/https.rb
parentd87a26c96e51a28416f5a6af1b0999c5fda5fe5e (diff)
Fixed to be less verbose, if we're running quietly
Diffstat (limited to 'worker/tests/https.rb')
-rwxr-xr-xworker/tests/https.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/worker/tests/https.rb b/worker/tests/https.rb
index 77739d1..fcc716b 100755
--- a/worker/tests/https.rb
+++ b/worker/tests/https.rb
@@ -62,7 +62,7 @@ class HTTPSTest
# Do we need to test for a HTTP status code?
#
if ( @test_data["http_status"] )
- puts "Testing for HTTP status code: #{@test_data['http_status']}"
+ puts "Testing for HTTP status code: #{@test_data['http_status']}" if ( @test_data['verbose'] )
if ( @status != @test_data['http_status'].to_i)
@error = "#{@error} status code was #{@status} not #{@test_data['http_status']}"
@@ -73,7 +73,7 @@ class HTTPSTest
# Do we need to search for text in the body of the reply?
#
if ( @test_data['http_text'] )
- puts "Testing for text in the response: #{@test_data['http_text']}"
+ puts "Testing for text in the response: #{@test_data['http_text']}" if ( @test_data['verbose'] )
if (! @body.match(/#{@test_data['http_text']}/i) )
@error = "#{@error} The respond did not contain #{test_data['http_text']}"
@@ -156,8 +156,8 @@ if __FILE__ == $0 then
test = {
"target_host" => "http://www.steve.org.uk/",
"test_type" => "http",
- "test_port" => 80,
"verbose" => 1,
+ "test_port" => 80,
"test_alert" => "Steve's website is unavailable",
"http_text" => "Steve Kemp",
"http_status" => "200"