Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I update phpunit?

Tags:

php

phpunit

pear

I have already tried everything, including https://stackoverflow.com/a/8740349/251311 and all possible channel upgrade and clear cache commands. But still:

$ sudo pear install -a -f phpunit/PHPUnit
downloading PHPUnit-3.6.12.tgz ...
Starting to download PHPUnit-3.6.12.tgz (120,240 bytes)
..........................done: 120,240 bytes
install ok: channel://pear.phpunit.de/PHPUnit-3.6.12

while:

$ pear list-upgrades
Channel pear.php.net: No upgrades available
pear.phpunit.de Available Upgrades (stable):
============================================
Channel         Package            Local           Remote          Size
pear.phpunit.de PHPUnit            3.6.12 (stable) 3.7.10 (stable) 115kB
pear.phpunit.de PHPUnit_MockObject 1.1.1 (stable)  1.2.2 (stable)  19.9kB
pear.phpunit.de PHPUnit_Selenium   1.2.8 (stable)  1.2.11 (stable) 38kB
pear.phpunit.de PHP_CodeCoverage   1.1.4 (stable)  1.2.7 (stable)  155kB
pear.phpunit.de PHP_TokenStream    1.1.4 (stable)  1.1.5 (stable)  9.7kB
pear.phpunit.de Text_Template      1.1.3 (stable)  1.1.4 (stable)  3.6kB

Award

There will be 100 points bounty for a person who will hint what can cause PEAR not be able to upgrade phpunit to the latest possible (using PEAR).

like image 897
zerkms Avatar asked Oct 05 '22 12:10

zerkms


2 Answers

Well, I use ubuntu lts 10.04, and it has php 5.3.2 version.

While phpunit 3.7 depends on php >= 5.3.3 (though it's not shown explicitly anywhere)

like image 167
zerkms Avatar answered Oct 11 '22 00:10

zerkms


I updated my Ubuntu to 12.10, which gives me PHP 5.4.x, and then the newer version of PHPUnit as well. I believe you need the 5.4.x of PHP to use the latest PHPUnit. Try updating PHP to be 5.4.x and then try the PHPUnit update again.

like image 39
Steven Scott Avatar answered Oct 11 '22 00:10

Steven Scott