hasSubCommandConfig() public méthode

Returns whether the command has a sub-command with a given name.
See also: beginSubCommand()
public hasSubCommandConfig ( string $name ) : boolean
$name string The name of the sub-command.
Résultat boolean Returns `true` if the sub-command configuration with the given name exists and `false` otherwise.
 public function testHasSubCommandConfig()
 {
     $this->config->addSubCommandConfig($config = new SubCommandConfig());
     $this->assertFalse($this->config->hasSubCommandConfig('command'));
     $this->assertFalse($this->config->hasSubCommandConfig('foobar'));
     $config->setName('command');
     $this->assertTrue($this->config->hasSubCommandConfig('command'));
     $this->assertFalse($this->config->hasSubCommandConfig('foobar'));
 }