prophesize(Command::class); $command->getName()->willReturn($name); $command->getDefinition()->willReturn($name); $command->isEnabled()->willReturn(true); $command->getAliases()->willReturn([]); $command->setApplication(Argument::type(Application::class))->willReturn(function (): void { }); return $command; } }