Remove messages.inc, rebuildLanguage.php, writeMessagesArray.inc
[mediawiki.git] / tests / phpunit / install-phpunit.sh
blob022f998e814421c2ef2ecbaf3f2081c784b88af1
1 #!/bin/sh
3 has_binary () {
4 if [ -z `which $1` ]; then
5 return 1
6 fi
7 return 0
10 if [ `id -u` -ne 0 ]; then
11 echo '*** ERROR: Must be root to run'
12 exit 1
15 if ( has_binary phpunit ); then
16 echo PHPUnit already installed
17 else if ( has_binary pear ); then
18 echo Installing phpunit with pear
19 pear channel-discover pear.phpunit.de
20 pear channel-discover components.ez.no
21 pear channel-discover pear.symfony.com
22 pear update-channels
23 #Temporary fix for 64597
24 pear install --alldeps phpunit/PHPUnit-3.7.35
25 else if ( has_binary apt-get ); then
26 echo Installing phpunit with apt-get
27 apt-get install phpunit
28 else if ( has_binary yum ); then
29 echo Installing phpunit with yum
30 yum install phpunit
31 else if ( has_binary port ); then
32 echo Installing phpunit with macports
33 port install php5-unit