2011-06-26 77 views
1

我知道最近有很多關於PHPUnit問題的討論,我花了四天的時間試圖讓PHPUnit安裝在我的Windows 7計算機上。我已經確認我升級了PEAR,以便它是最新的。當我安裝PHPUnit我得到如下:PHPUnit輸入文件問題

C:\Users\Marc>pear install --alldeps phpunit/PHPUnit 
phpunit/PHPUnit can optionally use PHP extension "curl" 
phpunit/PHPUnit can optionally use PHP extension "dbus" 
downloading PHPUnit-3.5.14.tgz ... 
Starting to download PHPUnit-3.5.14.tgz (118,697 bytes) 
..........................done: 118,697 bytes 
install ok: channel://pear.phpunit.de/PHPUnit-3.5.14 

C:\Users\Marc> 

所以,據我所知,一切順利的話......現在,當我嘗試調用phpunit我得到了以下問題:

無法打開輸入文件C:\ server \ www \ phpunit

有沒有人有一個想法如何解決這個問題?

+2

確保你在系統PATH中有phpunit.bat文件。 –

+0

它已經在路徑中 –

+0

嘗試調用'phpunit.bat'而不是'phpunit'。這是否工作? – hakre

回答

1

找出.bat文件PHPUnit的與

$ pear list phpunit/phpunit 

安裝會有像

script C:\foo\bar\baz\bin\phpunit.bat 

行此目錄(C:\foo\bar\baz\bin\)需要在您的PATH變量。

+0

試過了,它已經在路徑中了 –

+0

如果執行完整路徑,會得到什麼結果? – cweiske

+0

我得到同樣的問題 –