public function let($die, EntityManager $entityManager, TopicRepository $topicRepository) { $entityManager->getRepository('Newscoop\\NewscoopBundle\\Entity\\Topic')->willReturn($topicRepository); $this->beConstructedWith($entityManager); }