$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();
$r1 =
new \
ReflectionMethod($controller, 'regularCallable'
);
$r2 =
new \
ReflectionMethod($controller, 'staticControllerMethod'
);
$r3 =
new \
ReflectionClass($controller);
// test name, callable, expected
return [ [ '"Regular" callable',
[$controller, 'regularCallable'
],
[