injectController example

$this->assertEquals([]$c->getRouteParams());
    }

    /** * @dataProvider provideControllerCallables */
    public function testControllerInspection($name$callable$expected)
    {
        $c = new RequestDataCollector();
        $request = $this->createRequest();
        $response = $this->createResponse();
        $this->injectController($c$callable$request);
        $c->collect($request$response);
        $c->lateCollect();

        $this->assertSame($expected$c->getController()->getValue(true)sprintf('Testing: %s', $name));
    }

    public static function provideControllerCallables(): array
    {
        // make sure we always match the line number         $controller = new DummyController();

        
Home | Imprint | This part of the site doesn't use cookies.