controller = new ControllerCandidate(); } /** * @throws \PHPUnit\Framework\MockObject\Exception * @throws Exception */ public function testGoToForm(): void { $modelMock = $this->createMock(ModelCandidate::class); $modelMock->expects($this->once()) ->method('getForm') ->willReturn('
'); $this->controller->goToForm(); $this->expectOutputRegex('/