public hasArguments ( ) : boolean | ||
return | boolean |
public function hasArguments()
{
return count($this->getCommandMethodReflection()->getParameters()) > 0;
}
/** * @test */ public function hasArgumentsReturnsTrueIfCommandExpectsArguments() { $parameterReflection = $this->createMock(ParameterReflection::class, [], [[__CLASS__, 'dummyMethod'], 'arg']); $this->methodReflection->expects($this->atLeastOnce())->method('getParameters')->will($this->returnValue([$parameterReflection])); $this->assertTrue($this->command->hasArguments()); }