例外が発生しています
PDOException: You cannot serialize or unserialize PDO instances
単体テストに PHPUnit を使用しようとしているとき。私はあまり進んでいません。Zend Framework 1.11 を使用しています。Zend_Registry にエンティティ マネージャを格納するアプリケーションをブートストラップしたのではないでしょうか?
// application/Bootstrap.php -> _initDoctrine()
$em = EntityManager::create($doctrineOptions['connectionOptions'], $config);
Zend_Registry::set("em", $em);
私の単体テストでは、次のようになります
class Application_Models_UserTest extends Zend_Test_PHPUnit_ControllerTestCase
public function testUnitTest() {
$this->assertTrue(true);
}
}
私の phpunit.xml はhttp://pastebin.com/BCv2Ci8Rのように見えます。主な関心領域は 1 行目だと思います。つまり、bootstrap.php はhttp://pastebin.com/hVZhJAG1のようになります。
アップデート
行があるときに問題が発生することがわかりました
$schemaTool->dropSchema($classes);
$schemaTool->updateSchema($classes);
bootstrap.php でhttp://pastebin.com/hVZhJAG1