merge() public method

Existing commands are preserved. Commands with the same names as the passed commands are overwritten.
public merge ( array $commands )
$commands array The commands to add.
 public function testMerge()
 {
     $this->collection->add($ls = new Command(new CommandConfig('ls')));
     $this->collection->merge(array($cd = new Command(new CommandConfig('cd')), $cat = new Command(new CommandConfig('cat'))));
     $this->assertSame(array('ls' => $ls, 'cd' => $cd, 'cat' => $cat), $this->collection->toArray());
 }