debuginfod test: assert curl & rpm2cpio during test prologue

On debian & ubuntu hosts, rpm2cpio is not available by default,
and heck, curl might not be either.  Check for both these programs
during tests/run-debuginfod-find.sh startup, else exit-77 (skip).

Signed-off-by: Frank Ch. Eigler <fche@redhat.com>
diff --git a/tests/run-debuginfod-find.sh b/tests/run-debuginfod-find.sh
index 83ab338..6b5dbf8 100755
--- a/tests/run-debuginfod-find.sh
+++ b/tests/run-debuginfod-find.sh
@@ -18,6 +18,9 @@
 
 . $srcdir/test-subr.sh  # includes set -e
 
+type curl 2>/dev/null || (echo "need curl"; exit 77)
+type rpm2cpio 2>/dev/null || (echo "need rpm2cpio"; exit 77)
+
 # for test case debugging, uncomment:
 # set -x
 # VERBOSE=-vvvv
@@ -330,15 +333,13 @@
 
 ########################################################################
 
-# Fetch some metrics, if curl program is installed
-if type curl 2>/dev/null; then
-    curl -s http://127.0.0.1:$PORT1/badapi
-    curl -s http://127.0.0.1:$PORT1/metrics
-    curl -s http://127.0.0.1:$PORT2/metrics
-    curl -s http://127.0.0.1:$PORT1/metrics | grep -q 'http_responses_total.*result.*error'
-    curl -s http://127.0.0.1:$PORT1/metrics | grep -q 'http_responses_total.*result.*fdcache'
-    curl -s http://127.0.0.1:$PORT2/metrics | grep -q 'http_responses_total.*result.*upstream'
-fi
+# Fetch some metrics
+curl -s http://127.0.0.1:$PORT1/badapi
+curl -s http://127.0.0.1:$PORT1/metrics
+curl -s http://127.0.0.1:$PORT2/metrics
+curl -s http://127.0.0.1:$PORT1/metrics | grep -q 'http_responses_total.*result.*error'
+curl -s http://127.0.0.1:$PORT1/metrics | grep -q 'http_responses_total.*result.*fdcache'
+curl -s http://127.0.0.1:$PORT2/metrics | grep -q 'http_responses_total.*result.*upstream'
 
 ########################################################################