Pear-phpunit
Moderator: General Moderators
Pear-phpunit
I want to install phpUnit 3. I have installed pear. When I open Web-based PEAR Frontend and searched for PHPUnit 3. It is only showing phpunit 1.3.3. Where can i get PHPUnit 3.
- Maugrim_The_Reaper
- DevNet Master
- Posts: 2704
- Joined: Tue Nov 02, 2004 5:43 am
- Location: Ireland
First of all make sure you know how to use PEAR Installer from the command line. Check the PEAR site for the documentation.
Uninstall all PEAR default PHPUnit packages - then go check the PEAR directory to ensure they were all deleted. If actually require v1 or v2 obviously you need to rethink this.
Then? It's in the manual.
http://www.phpunit.de/pocket_guide/3.0/ ... ation.html
You'll have PHPUnit 3 running in no time...
Uninstall all PEAR default PHPUnit packages - then go check the PEAR directory to ensure they were all deleted. If actually require v1 or v2 obviously you need to rethink this.
Then? It's in the manual.
http://www.phpunit.de/pocket_guide/3.0/ ... ation.html
You'll have PHPUnit 3 running in no time...
I installed pear through go-pear. My OS is windows. When i search for PHPUnit 3 it shows no results. but, when i click [ list available upgrades ] PHPUnit 3 is listed in the results. If i click on update, it gives the error Will upgrade channel://pear.phpunit.de/phpunit
phpunit/phpunit is already installed and is newer than detected release version 1.3.3
Cannot initialize 'channel://pear.phpunit.de/phpunit', invalid or missing package file
upgrade-all failed
phpunit/phpunit is already installed and is newer than detected release version 1.3.3
Cannot initialize 'channel://pear.phpunit.de/phpunit', invalid or missing package file
upgrade-all failed
- Maugrim_The_Reaper
- DevNet Master
- Posts: 2704
- Joined: Tue Nov 02, 2004 5:43 am
- Location: Ireland
Uninstalled and reinstalled. Still i am only able to install 1.3.3 version. Is PHPUnit 1.3 + is moved out of pear? When i was searching in google, i got this info. Check this link http://marc.info/?l=pear-dev&m=115212195328840&w=2
- Maugrim_The_Reaper
- DevNet Master
- Posts: 2704
- Joined: Tue Nov 02, 2004 5:43 am
- Location: Ireland
The PEAR versions are no longer sourced from PHPUnit.de - the dev team have their own PEAR channel now.
What PEAR install command are you using? Are you declaring the channel you're installing from?
What PEAR install command are you using? Are you declaring the channel you're installing from?
notpear install phpunit/PHPUnit
If it's still not working, try the manual installation instructions from the manual. Can you also check you're actually working from the correct pear/php install. I know one can be bitten if there are a few PHP installs or php.ini files sitting on your PATH.pear install PHPUnit
channel: pear.phpunit.de. Is this correct channel?
For manual installation,
I downloaded PHPUnit-3.0.6.tgz and extracted.
I am not able to rename the pear-phpunit to phpunit (it says allready a file has the same name. (The extracted folder has 2 folders - PHPUnit, PHPUnit2. 1 script file, pear-phpunit and pear-phpunit batch file)).
For manual installation,
I downloaded PHPUnit-3.0.6.tgz and extracted.
I am not able to rename the pear-phpunit to phpunit (it says allready a file has the same name. (The extracted folder has 2 folders - PHPUnit, PHPUnit2. 1 script file, pear-phpunit and pear-phpunit batch file)).
- Maugrim_The_Reaper
- DevNet Master
- Posts: 2704
- Joined: Tue Nov 02, 2004 5:43 am
- Location: Ireland
I think you have artifacts of a previous installation. Things shouldn't be conflicting like this from a fresh start. I mean if a simple rename is being refused then where's the file blocking it?
What system exactly are you running? Some prebuilt packages on Windows (like XAMPP) can sometimes read-only PEAR files and scripts and prevent a wholesale delete of them. The same problem can also leave a PEAR install unfinished.
What system exactly are you running? Some prebuilt packages on Windows (like XAMPP) can sometimes read-only PEAR files and scripts and prevent a wholesale delete of them. The same problem can also leave a PEAR install unfinished.
I renamed it as phpunit.php. The paths of the files are as below. I am working on Windows.
.ini file has:- include_path = ".;c:\php\includes".
wamp is installed in c:\. (C:\wamp).
i placed the downloaded phpunit files in : C:\wamp\php\includes\PHPUnit-3.0.6\PHPUnit-3.0.6
Placed phpunit.php in: C:\wamp\www\phpunit\phpunit.php. In the script i replaced @ @ with #!c:\wamp\php\
In the class file, i have written
to test whether its working or not. Its not working.
It is giving,
Warning: require_once(PHPUnit-3.0.6\PHPUnit-3.0.6\PHPUnit\Framework.php) [function.require-once]: failed to open stream: No such file or directory in
Pls let me know where i made wrong.
.ini file has:- include_path = ".;c:\php\includes".
wamp is installed in c:\. (C:\wamp).
i placed the downloaded phpunit files in : C:\wamp\php\includes\PHPUnit-3.0.6\PHPUnit-3.0.6
Placed phpunit.php in: C:\wamp\www\phpunit\phpunit.php. In the script i replaced @ @ with #!c:\wamp\php\
In the class file, i have written
Code: Select all
require_once 'PHPUnit-3.0.6\PHPUnit-3.0.6\PHPUnit\Framework.php';It is giving,
Warning: require_once(PHPUnit-3.0.6\PHPUnit-3.0.6\PHPUnit\Framework.php) [function.require-once]: failed to open stream: No such file or directory in
Pls let me know where i made wrong.