phpstorm設定phpunit,進行php介面單元測試
1。安裝php5.6,phpunit5.1,curl
mac 自帶的預設是php5.5,需要升級,開啟終端,運作:curl -s http://php-osx.liip.ch/install.sh | bash -s 5.6
查看phpunit官網文檔,依照文檔步驟
1 2 3 |
|
2。下載phpunit.phar文件,然後在phpstorm 中加載,如圖
第二個就是phpunit.phar的路徑
3.。載入phpunit安裝目錄:
4.。選擇編譯器
5,根據curl 模擬訪問接口,
1 2 |
|
以上就介紹了phpstorm配置phpunit,進行php單元測試,包括了方面的內容,希望對PHP教程有興趣的朋友有所幫助教程