protected function loadImagesFromInfoboxes($articleIds)
 {
     wfProfileIn(__METHOD__);
     $images = [];
     foreach ($articleIds as $id) {
         $images = array_merge($images, PortableInfoboxDataService::newFromPageID($id)->getImages());
     }
     if ($images) {
         $details = $this->loadImagesMetadata($images);
         foreach ($details as $name => $row) {
             //set popularity to one, to trick image serving
             $this->addImageDetails($row->img_name, '1', $row->img_width, $row->img_height, $row->img_minor_mime);
         }
     }
     wfProfileOut(__METHOD__);
 }
 public function testConstructor()
 {
     $service = PortableInfoboxDataService::newFromPageID(null);
     $result = $service->getData();
     $this->assertEquals([], $result);
 }