當前位置: 首頁>>代碼示例>>PHP>>正文


PHP PHPUnit_Util_Printer::flush方法代碼示例

本文整理匯總了PHP中PHPUnit_Util_Printer::flush方法的典型用法代碼示例。如果您正苦於以下問題:PHP PHPUnit_Util_Printer::flush方法的具體用法?PHP PHPUnit_Util_Printer::flush怎麽用?PHP PHPUnit_Util_Printer::flush使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在PHPUnit_Util_Printer的用法示例。


在下文中一共展示了PHPUnit_Util_Printer::flush方法的10個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: flush

 public function flush()
 {
     if (!$this->rootTestSuiteWrote) {
         $emptyTestSuite = new \PHPUnit_Framework_TestSuite();
         $this->startTestSuite($emptyTestSuite);
         $this->endTestSuite($emptyTestSuite);
     }
     $this->junitXMLWriter->endTestSuites();
     parent::flush();
 }
開發者ID:piece,項目名稱:stagehand-testrunner,代碼行數:10,代碼來源:JUnitXMLPrinter.php

示例2: flush

 /**
  * Flush buffer and close output.
  */
 public function flush()
 {
     $this->doEndClass();
     $this->endRun();
     parent::flush();
 }
開發者ID:luchaninov,項目名稱:phpunit,代碼行數:9,代碼來源:ResultPrinter.php

示例3: flush

 /**
  * Flush buffer and close output.
  *
  * @access public
  */
 public function flush()
 {
     $this->write($this->graph->parse());
     parent::flush();
 }
開發者ID:dalinhuang,項目名稱:shopexts,代碼行數:10,代碼來源:GraphViz.php

示例4: flush

 /**
  * Flush buffer and close output.
  */
 public function flush()
 {
     if ($this->writeDocument === true) {
         $this->write($this->getXML());
     }
     parent::flush();
 }
開發者ID:ronaldbao,項目名稱:phpunit,代碼行數:10,代碼來源:JUnit.php

示例5: flush

 /**
  * Flush: Copy images and additional files to folder and generate index file using a template
  *
  * This method is called once after all tests have been processed.
  * HINT: The flush method is only called if the TestListener inherits from PHPUnit_Util_Printer
  *
  * @param array $templateVars
  * @return void
  * @author Fabrizio Branca
  */
 public function flush(array $templateVars = array())
 {
     $this->copyAdditionalFiles();
     $className = $this->viewClass;
     $view = new $className($this->templateFile);
     /* @var $view Menta_Util_View  */
     if (!$view instanceof Menta_Util_View) {
         throw new Exception('View must inherit from Menta_Util_View.');
     }
     foreach ($templateVars as $key => $value) {
         $view->assign($key, $value);
     }
     $this->write($view->render());
     return parent::flush();
 }
開發者ID:aoemedia,項目名稱:menta,代碼行數:25,代碼來源:AbstractTemplatablePrinter.php

示例6: flush

 /**
  * @inheritdoc
  */
 public function flush()
 {
     if (0 === $this->assertions) {
         return;
     }
     $report = array('@context' => array('doap' => 'http://usefulinc.com/ns/doap#', 'foaf' => 'http://xmlns.com/foaf/0.1/', 'dc' => 'http://purl.org/dc/terms/', 'earl' => 'http://www.w3.org/ns/earl#', 'xsd' => 'http://www.w3.org/2001/XMLSchema#', 'doap:homepage' => array('@type' => '@id'), 'doap:license' => array('@type' => '@id'), 'dc:creator' => array('@type' => '@id'), 'foaf:homepage' => array('@type' => '@id'), 'subjectOf' => array('@reverse' => 'earl:subject'), 'earl:assertedBy' => array('@type' => '@id'), 'earl:mode' => array('@type' => '@id'), 'earl:test' => array('@type' => '@id'), 'earl:outcome' => array('@type' => '@id'), 'dc:date' => array('@type' => 'xsd:date')), '@id' => $this->options['project-url'], '@type' => array('doap:Project', 'earl:TestSubject', 'earl:Software'), 'doap:name' => $this->options['project-name'], 'dc:title' => $this->options['project-name'], 'doap:homepage' => $this->options['project-homepage'], 'doap:license' => $this->options['license-url'], 'doap:description' => $this->options['project-description'], 'doap:programming-language' => $this->options['programming-language'], 'doap:developer' => array('@id' => $this->options['developer-url'], '@type' => array('foaf:Person', 'earl:Assertor'), 'foaf:name' => $this->options['developer-name'], 'foaf:homepage' => $this->options['developer-homepage']), 'dc:creator' => $this->options['developer-url'], 'dc:date' => array('@value' => date('Y-m-d'), '@type' => 'xsd:date'), 'subjectOf' => $this->assertions);
     $options = 0;
     if (PHP_VERSION_ID >= 50400) {
         $options |= JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE | JSON_PRETTY_PRINT;
         $report = json_encode($report, $options);
     } else {
         $report = json_encode($report);
         $report = str_replace('\\/', '/', $report);
         // unescape slahes
         // unescape unicode
         $report = preg_replace_callback('/\\\\u([a-f0-9]{4})/', function ($match) {
             return iconv('UCS-4LE', 'UTF-8', pack('V', hexdec($match[1])));
         }, $report);
     }
     $this->write($report);
     parent::flush();
 }
開發者ID:janul,項目名稱:JsonLD,代碼行數:25,代碼來源:EarlReportGenerator.php

示例7: flush

 /**
  * Flush buffer and close output.
  */
 public function flush()
 {
     $this->write($this->document->saveXML());
     parent::flush();
 }
開發者ID:thanghexp,項目名稱:project,代碼行數:8,代碼來源:XML.php

示例8: flush

 public function flush()
 {
     $this->junitXMLWriter->endTestSuites();
     parent::flush();
 }
開發者ID:rsky,項目名稱:stagehand-testrunner,代碼行數:5,代碼來源:JUnitXMLPrinter.php

示例9: flush

 public function flush()
 {
     parent::flush();
     $this->saveCheckstyleReport();
     $this->printOutputReport();
 }
開發者ID:munkie,項目名稱:symfony-deprecation-phpunit-reporter,代碼行數:6,代碼來源:DeprecationListener.php

示例10: flush

 public function flush()
 {
     $this->xmlWriter->endTestSuites();
     parent::flush();
 }
開發者ID:rsky,項目名稱:makegood,代碼行數:5,代碼來源:JUnitXMLPrinter.php


注:本文中的PHPUnit_Util_Printer::flush方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。