getEngines() public method

Get the array of engine data
public getEngines ( ) : Engine[]
return Engine[]
コード例 #1
0
 /**
  * tests getting an existing engine
  *
  * @group data
  * @group sourcetest
  */
 public function testGetEngine()
 {
     $this->object->addEnginesFile($this->getEngineJsonFixture());
     self::assertInternalType('array', $this->object->getEngines());
     $engine = $this->object->getEngine('Foobar');
     self::assertInstanceOf('\\Browscap\\Data\\Engine', $engine);
     $properties = $engine->getProperties();
     self::assertInternalType('array', $properties);
     self::assertArrayHasKey('RenderingEngine_Name', $properties);
     self::assertSame('Foobar', $properties['RenderingEngine_Name']);
 }