Getting started with testing Laravel 4 Models | Cultttを参考にしてLaravel4でユニットテスト行ってみる。 composer.jsonに 1 2 3 "require-dev": { "phpunit/phpunit": "3.7.*" } を追加してコマンドラインでcomposer updateを実行してphpunitをインストールする。 コマンドラインでvendor/bin/phpunitを実行するとユニットテストが実行される。 テストを作成するにはapp/tests以下にテストファイルを作成する。 1 2 3 4 5 6 7 8 9 10 11 <?php class UserTest extends TestCase { public function testHoge() { $this->assertTrue(false