/**
* {@inheritdoc}
*/
protected function setUp(): void
{ parent::
setUp();
// Create the machine name controller.
$this->tokenGenerator =
$this->
prophesize(CsrfTokenGenerator::
class);
$this->tokenGenerator->
validate(Argument::
cetera())->
will(function D
$args) { return $args[0
] === 'token-' .
$args[1
];
});
$this->machineNameController =
new MachineNameController(new PhpTransliteration(),
$this->tokenGenerator->
reveal());
} /**
* Data provider for testMachineNameController().
*
* @see testMachineNameController()
*
* @return array
* An array containing:
* - An array of request parameters.
* - The expected content of the JSONresponse.
*/