当前位置: 首页>>代码示例>>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;未经允许,请勿转载。