/**
  * @dataProvider testProvider
  */
 public function testCreatesCommandsUsingServiceDescriptions($key, $result)
 {
     $d = $this->getDescription();
     $factory = new ServiceDescriptionFactory($d);
     $this->assertSame($d, $factory->getServiceDescription());
     if (is_null($result)) {
         $this->assertNull($factory->factory($key));
     } else {
         $this->assertInstanceof($result, $factory->factory($key));
     }
 }
 /**
  * @covers Guzzle\Service\Command\Factory\ServiceDescriptionFactory
  * @dataProvider testProvider
  */
 public function testCreatesCommandsUsingServiceDescriptions($key, $result)
 {
     $d = ServiceDescription::factory(array('commands' => array('jarjar' => array('class' => 'Guzzle\\Tests\\Service\\Mock\\Command\\MockCommand'), 'binks' => array('class' => 'Guzzle\\Tests\\Service\\Mock\\Command\\OtherCommand'))));
     $factory = new ServiceDescriptionFactory($d);
     $this->assertSame($d, $factory->getServiceDescription());
     if (is_null($result)) {
         $this->assertNull($factory->factory($key));
     } else {
         $this->assertInstanceof($result, $factory->factory($key));
     }
 }