public function testPush()
 {
     $instance = new ProcessingErrorMsgHandler(DIWikiPage::newFromText(__METHOD__));
     $container = $this->getMockBuilder('\\SMWDIContainer')->disableOriginalConstructor()->getMock();
     $semanticData = $this->getMockBuilder('\\SMW\\SemanticData')->disableOriginalConstructor()->getMock();
     $semanticData->expects($this->once())->method('addPropertyObjectValue')->with($this->equalTo($this->dataItemFactory->newDIProperty('_ERRC')));
     $instance->pushTo($semanticData, $container);
 }
 /**
  * @since 1.9
  *
  * @param SMWDataValue $dataValue
  */
 public function addDataValue(SMWDataValue $dataValue)
 {
     if (!$dataValue->getProperty() instanceof DIProperty || !$dataValue->isValid()) {
         $processingErrorMsgHandler = new ProcessingErrorMsgHandler($this->getSubject());
         $processingErrorMsgHandler->pushTo($this, $processingErrorMsgHandler->getErrorContainerFromDataValue($dataValue));
         return $this->addError($dataValue->getErrors());
     }
     $this->addPropertyObjectValue($dataValue->getProperty(), $dataValue->getDataItem());
 }
 private function addProcessingError($errors)
 {
     $processingErrorMsgHandler = new ProcessingErrorMsgHandler($this->parserData->getSubject());
     foreach ($errors as $error) {
         $processingErrorMsgHandler->pushTo($this->parserData->getSemanticData(), $processingErrorMsgHandler->getErrorContainerFromMsg($error, new DIProperty('_ASK')));
     }
 }