diff options
Diffstat (limited to 'plugins/tests/check_http.t')
-rwxr-xr-x | plugins/tests/check_http.t | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/plugins/tests/check_http.t b/plugins/tests/check_http.t index 1bc0ecb7..dd567069 100755 --- a/plugins/tests/check_http.t +++ b/plugins/tests/check_http.t | |||
@@ -29,13 +29,16 @@ eval { | |||
29 | require HTTP::Response; | 29 | require HTTP::Response; |
30 | }; | 30 | }; |
31 | 31 | ||
32 | my $plugin = 'check_http'; | ||
33 | $plugin = 'check_curl' if $0 =~ m/check_curl/mx; | ||
34 | |||
32 | if ($@) { | 35 | if ($@) { |
33 | plan skip_all => "Missing required module for test: $@"; | 36 | plan skip_all => "Missing required module for test: $@"; |
34 | } else { | 37 | } else { |
35 | if (-x "./check_http") { | 38 | if (-x "./$plugin") { |
36 | plan tests => $common_tests * 2 + $ssl_only_tests; | 39 | plan tests => $common_tests * 2 + $ssl_only_tests; |
37 | } else { | 40 | } else { |
38 | plan skip_all => "No check_http compiled"; | 41 | plan skip_all => "No $plugin compiled"; |
39 | } | 42 | } |
40 | } | 43 | } |
41 | 44 | ||
@@ -179,7 +182,7 @@ if ($ARGV[0] && $ARGV[0] eq "-d") { | |||
179 | } | 182 | } |
180 | 183 | ||
181 | my $result; | 184 | my $result; |
182 | my $command = "./check_http -H 127.0.0.1"; | 185 | my $command = "./$plugin -H 127.0.0.1"; |
183 | 186 | ||
184 | run_common_tests( { command => "$command -p $port_http" } ); | 187 | run_common_tests( { command => "$command -p $port_http" } ); |
185 | SKIP: { | 188 | SKIP: { |