tools: Specify format of disks (RHBZ#642934,CVE-2010-3851).
[libguestfs.git] / php / run-php-tests.sh
1 #!/bin/sh -
2 # Copyright (C) 2010 Red Hat Inc.
3 #
4 # This program is free software; you can redistribute it and/or modify
5 # it under the terms of the GNU General Public License as published by
6 # the Free Software Foundation; either version 2 of the License, or
7 # (at your option) any later version.
8 #
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY; without even the implied warranty of
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12 # GNU General Public License for more details.
13 #
14 # You should have received a copy of the GNU General Public License
15 # along with this program; if not, write to the Free Software
16 # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
17
18 set -e
19 cd extension
20
21 TESTS=$(echo guestfs_php_*.phpt)
22 echo TESTS: $TESTS
23
24 # The PHP test script cleans the environment, so LIBGUESTFS_DEBUG=1
25 # won't get passed down to the script.  Furthermore, setting
26 # LIBGUESTFS_DEBUG=1 isn't very useful anyway because the PHP test
27 # script mixes stdout and stderr together and compares this to the
28 # expected output, so you'd just get failures for every test.  So
29 # there is no good way to debug libguestfs failures in PHP tests, but
30 # if an individual test fails locally then you can edit the
31 # guestfs_php_*.phpt and uncomment the putenv statement, then look at
32 # the output.
33 unset LIBGUESTFS_DEBUG
34
35 # By the way, we're actually testing the installed version of
36 # libguestfs.  But don't worry, because PHP ignores the result of the
37 # tests anyway! ** Gah, PHP is written by morons ... **
38 make test TESTS="$TESTS"