Homebrewをインストール
Homebrew — MacPorts driving you to drink? Try Homebrew!
PHPBrewをインストール
c9s/phpbrew
Requirementsの足りないものをhomebrewでインストール
phpbrewのインストールをhomebrew経由にするためFormulaを追加
Formula for phpbrew — Gist
ダウンロードして/usr/local/Library/Formulaに追加
brew install --HEAD phpbrew
以降のphpインストール、切替はphpbrewを参照
本当はphp-versionとphp-buildで管理したかったけど、
うまく行かなかったのでとりあえずこれで落ち着いた
xdebugのインストール
brew install php54-xdebug
指示に沿ってphp.iniにxdebugの設定を追記
PHPUnitをインストール
PHPUnit PEAR Channel
The symfony project PEAR channel
pear channel-discover pear.phpunit.de
pear channel-discover pear.symfony-project.com
pear install symfony/YAML
pear install phpunit/PHPUnit
こっちのやり方のほうがスマート
sebastianbergmann/phpunit
phpstormの設定
設定 > PHP > Development environment > Interpreterでインストールした各バージョンを指定する