From d5d347d7ce9fe25a07d32fb10fda47de3b029ee8 Mon Sep 17 00:00:00 2001 From: Sven Nierlein Date: Sat, 18 Mar 2017 22:48:35 +0100 Subject: check_curl: make check_curl use the same tests as check_http --- plugins/tests/check_curl.t | 1 + plugins/tests/check_http.t | 9 ++++++--- 2 files changed, 7 insertions(+), 3 deletions(-) create mode 120000 plugins/tests/check_curl.t (limited to 'plugins/tests') diff --git a/plugins/tests/check_curl.t b/plugins/tests/check_curl.t new file mode 120000 index 00000000..a54db967 --- /dev/null +++ b/plugins/tests/check_curl.t @@ -0,0 +1 @@ +check_http.t \ No newline at end of file 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 { require HTTP::Response; }; +my $plugin = 'check_http'; +$plugin = 'check_curl' if $0 =~ m/check_curl/mx; + if ($@) { plan skip_all => "Missing required module for test: $@"; } else { - if (-x "./check_http") { + if (-x "./$plugin") { plan tests => $common_tests * 2 + $ssl_only_tests; } else { - plan skip_all => "No check_http compiled"; + plan skip_all => "No $plugin compiled"; } } @@ -179,7 +182,7 @@ if ($ARGV[0] && $ARGV[0] eq "-d") { } my $result; -my $command = "./check_http -H 127.0.0.1"; +my $command = "./$plugin -H 127.0.0.1"; run_common_tests( { command => "$command -p $port_http" } ); SKIP: { -- cgit v1.2.3-74-g34f1