ZendFrameworkのControllerをPHPUnitでテストする

ブログが続かないわけ | PHP ZendFrameworkで作成したControllerをPHPUnitでテストする

Zend FrameworkのControllerをPHPUnitでテストする方法が書かれています。とても分かりやすくて素晴らしい記事だと思います!
自分でリクエストオブジェクトを用意して

[php]
$req = new Zend_Controller_Request_Http(‘http://localhost/sandbox/unitsample/index/index’);
[/php]

コマンドラインからのrunだけど、HTTP経由のリクエストとする、という。なるほどー。これは是非組み込んでいきたいです。

関連する記事:

Powered by

Leave a Comment


NOTE - You can use these HTML tags and attributes:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre lang="" line="" escaped="" highlight="">