From 4bf7240d3cc8f0f239a37872ce5385f655e7197d Mon Sep 17 00:00:00 2001 From: Athmane Madjoudj Date: Apr 15 2012 23:29:42 +0000 Subject: Merge commit 'refs/merge-requests/3' of git://gitorious.org/testautomation/t_functional into merge-requests/3 --- diff --git a/tests/p_curl/0-install_curl.sh b/tests/p_curl/0-install_curl.sh new file mode 100755 index 0000000..f77ff47 --- /dev/null +++ b/tests/p_curl/0-install_curl.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# Author: Athmane Madjoudj +# Christoph Galuschka + +t_Log "$0 - installing curl" +t_InstallPackage curl diff --git a/tests/p_curl/curl_test.sh b/tests/p_curl/curl_test.sh new file mode 100755 index 0000000..1ed1d1c --- /dev/null +++ b/tests/p_curl/curl_test.sh @@ -0,0 +1,18 @@ +#!/bin/sh +# Author: Athmane Madjoudj +# Christoph Galuschka + +t_Log "Running $0 - curl can access http-host and retrieve index.html." + +CHECK_FOR="CentOS Wiki" + +if [ $SKIP_QA_HARNESS ]; then + URL="http://wiki.centos.org/" +else + URL="http://repo.centos.qa/srv/CentOS/" +fi + +t_Log "Querying ${URL}" +curl -s ${URL} | grep -q "${CHECK_FOR}" + +t_CheckExitStatus $?