From fe414ccdda51b17f583c18dd8d94aaba54554aaa Mon Sep 17 00:00:00 2001 From: Marcin Juszkiewicz Date: Thu, 18 Apr 2013 09:41:11 +0200 Subject: OpenEmbedded: added tests for phpinfo and php/mysql Signed-off-by: Marcin Juszkiewicz --- openembedded/phpinfo.yaml | 19 +++++++++++++++++++ openembedded/phpmysql.yaml | 19 +++++++++++++++++++ openembedded/scripts/phpinfo.sh | 33 +++++++++++++++++++++++++++++++++ openembedded/scripts/phpmysql.sh | 33 +++++++++++++++++++++++++++++++++ 4 files changed, 104 insertions(+) create mode 100644 openembedded/phpinfo.yaml create mode 100644 openembedded/phpmysql.yaml create mode 100755 openembedded/scripts/phpinfo.sh create mode 100755 openembedded/scripts/phpmysql.sh diff --git a/openembedded/phpinfo.yaml b/openembedded/phpinfo.yaml new file mode 100644 index 0000000..ec82a06 --- /dev/null +++ b/openembedded/phpinfo.yaml @@ -0,0 +1,19 @@ +metadata: + name: phpinfo + format: "Lava-Test-Shell Test Definition 1.0" + description: "Test for phpinfo() in OE." + +install: + git-repos: + - git://git.linaro.org/qa/test-definitions.git + +run: + steps: + - "cd test-definitions/oe/scripts" + - "./phpinfo.sh" + +parse: + pattern: "^(?P[a-zA-Z0-9_-]+):\\s(?P\\w+)" + fixupdict: + PASS: pass + FAIL: fail diff --git a/openembedded/phpmysql.yaml b/openembedded/phpmysql.yaml new file mode 100644 index 0000000..4c0d517 --- /dev/null +++ b/openembedded/phpmysql.yaml @@ -0,0 +1,19 @@ +metadata: + name: phpmysql + format: "Lava-Test-Shell Test Definition 1.0" + description: "Test for php/mysql in OE." + +install: + git-repos: + - git://git.linaro.org/qa/test-definitions.git + +run: + steps: + - "cd test-definitions/oe/scripts" + - "./phpmysql.sh" + +parse: + pattern: "^(?P[a-zA-Z0-9_-]+):\\s(?P\\w+)" + fixupdict: + PASS: pass + FAIL: fail diff --git a/openembedded/scripts/phpinfo.sh b/openembedded/scripts/phpinfo.sh new file mode 100755 index 0000000..43a2731 --- /dev/null +++ b/openembedded/scripts/phpinfo.sh @@ -0,0 +1,33 @@ +#!/bin/bash +# +# PHP test. +# +# Copyright (C) 2013, Linaro Limited. +# +# This program is free software; you can redistribute it and/or +# modify it under the terms of the GNU General Public License +# as published by the Free Software Foundation; either version 2 +# of the License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. +# +# Author: Marcin Juszkiewicz +# + +wget http://localhost/info.php > phpinfo.log + +if [ 0 -eq $? ] +then + echo "phpinfo: pass" + exit 0 +else + echo "phpinfo: fail" + exit 1 +fi diff --git a/openembedded/scripts/phpmysql.sh b/openembedded/scripts/phpmysql.sh new file mode 100755 index 0000000..6d40b45 --- /dev/null +++ b/openembedded/scripts/phpmysql.sh @@ -0,0 +1,33 @@ +#!/bin/bash +# +# PHP test. +# +# Copyright (C) 2013, Linaro Limited. +# +# This program is free software; you can redistribute it and/or +# modify it under the terms of the GNU General Public License +# as published by the Free Software Foundation; either version 2 +# of the License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. +# +# Author: Marcin Juszkiewicz +# + +wget http://localhost/mysql.php > phpmysql.log + +if [ 0 -eq $? ] +then + echo "phpmysql: pass" + exit 0 +else + echo "phpmysql: fail" + exit 1 +fi -- cgit v1.2.3