1
リダイレクト後にアサーションを正しく行うには?リダイレクト後にサイトをチェックする方法は? DomCrawler。機能テスト
$crawler = $client->submit($form);
$client->followRedirect();
//$response = $client->getResponse()->getContent();
$this->assertTrue($crawler->filter('html:contains("foo")')->count() > 0);
デバッガは$response
がfoo
言葉で、私は期待していたコンテンツを持っていることを示しているが、アサーションが失敗しました。