/**
  * @since 1.9
  *
  * @return UnusedPropertiesQueryPage
  */
 private function newInstance($result = null, $values = array())
 {
     $collector = $this->newMockBuilder()->newObject('CacheableResultCollector', array('getResults' => $result));
     $mockStore = $this->newMockBuilder()->newObject('Store', array('getPropertyValues' => $values, 'getUnusedPropertiesSpecial' => $collector));
     $instance = new UnusedPropertiesQueryPage($mockStore, $this->newSettings());
     $instance->setContext($this->newContext());
     return $instance;
 }
 /**
  * @since 1.9
  *
  * @return UnusedPropertiesQueryPage
  */
 private function newInstance($result = null, $values = array())
 {
     $listLookup = $this->getMockBuilder('\\SMW\\SQLStore\\Lookup\\ListLookup')->disableOriginalConstructor()->getMock();
     $listLookup->expects($this->any())->method('fetchList')->will($this->returnValue($result));
     $mockStore = $this->newMockBuilder()->newObject('Store', array('getPropertyValues' => $values, 'getUnusedPropertiesSpecial' => $listLookup));
     $instance = new UnusedPropertiesQueryPage($mockStore, $this->newSettings());
     $instance->setContext($this->newContext());
     return $instance;
 }
 /**
  * @see SpecialPage::execute
  */
 public function execute($param)
 {
     $out = $this->getOutput();
     $out->setPageTitle($this->msg('unusedproperties')->text());
     $page = new UnusedPropertiesQueryPage($this->getStore(), $this->getSettings());
     $page->setContext($this->getContext());
     list($limit, $offset) = $this->getLimitOffset();
     $page->doQuery($offset, $limit);
     // Ensure locally collected output data is pushed to the output!
     SMWOutputs::commitToOutputPage($out);
 }