当前位置: 首页>>代码示例>>PHP>>正文


PHP SimpleReporter::paintCaseStart方法代码示例

本文整理汇总了PHP中SimpleReporter::paintCaseStart方法的典型用法代码示例。如果您正苦于以下问题:PHP SimpleReporter::paintCaseStart方法的具体用法?PHP SimpleReporter::paintCaseStart怎么用?PHP SimpleReporter::paintCaseStart使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在SimpleReporter的用法示例。


在下文中一共展示了SimpleReporter::paintCaseStart方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: paintCaseStart

 /**
  *    Paints the start of a test case. Will also paint
  *    the page header and footer if this is the
  *    first test. Will stash the size if the first
  *    start.
  *    @param string $test_name   Name of test that is starting.
  *    @access public
  */
 public function paintCaseStart($test_name)
 {
     parent::paintCaseStart($test_name);
     echo '<h2>' . $test_name . '</h2>';
     echo '<div class="test-reports">';
     flush();
 }
开发者ID:ivantcholakov,项目名称:Bonfire,代码行数:15,代码来源:my_reporter.php

示例2: run

 /**
  *    Invokes run() on all of the held test cases, instantiating
  *    them if necessary.
  *    @param SimpleReporter $reporter    Current test reporter.
  *    @param int $port Port to report test results on
  *    @access public
  */
 function run(&$reporter, $port)
 {
     $count = count($this->_test_cases);
     for ($i = 0; $i < $count; $i++) {
         if (is_string($this->_test_cases[$i])) {
             $class = $this->_test_cases[$i];
             $test =& new $class();
             ob_start();
             $reporter->paintGroupStart($this->getLabel(), $this->getSize());
             $reporter->paintCaseStart($test->getLabel());
             $start = ob_get_contents();
             ob_end_clean();
             ob_start();
             $reporter->paintCaseEnd($test->getLabel());
             $reporter->paintGroupEnd($this->getLabel());
             $end = ob_get_contents();
             ob_end_clean();
             //the guts from SimpleTestCase::run($reporter) where
             $test->_runner = new EclipseRunner($test, $reporter, $start, $end, $port);
             $test->_runner->run();
             $output = $start;
             if ($i + 1 == $count) {
                 $output .= "<done/>";
             }
             $output .= $end;
             $sock = new SimpleSocket("127.0.0.1", $port, 5);
             $sock->write($output);
             $sock->close();
             echo $sock->getError();
         } else {
             $this->_test_cases[$i]->run($reporter, $port);
         }
     }
     return $reporter->getStatus();
 }
开发者ID:sebs,项目名称:simpletest,代码行数:42,代码来源:eclipsetest.php

示例3: paintCaseStart

 function paintCaseStart($test_name)
 {
     parent::paintCaseStart($test_name);
     print $this->_getIndent();
     print "<" . $this->_namespace . "case>\n";
     print $this->_getIndent(1);
     print "<" . $this->_namespace . "name>" . $this->toParsedXml($test_name) . "</" . $this->_namespace . "name>\n";
 }
开发者ID:BackupTheBerlios,项目名称:phpbase-svn,代码行数:8,代码来源:xml.php

示例4: run

 /**
  *    Uses reflection to run every method within itself
  *    starting with the string "test" unless a method
  *    is specified.
  *    @param SimpleReporter $reporter    Current test reporter.
  *    @access public
  */
 function run(&$reporter)
 {
     $reporter->paintCaseStart($this->getLabel());
     $this->_runner =& $this->_createRunner($reporter);
     $this->_runner->run();
     $reporter->paintCaseEnd($this->getLabel());
     return $reporter->getStatus();
 }
开发者ID:radicaldesigns,项目名称:amp,代码行数:15,代码来源:simple_test.php

示例5: paintCaseStart

 function paintCaseStart($test_name)
 {
     parent::paintCaseStart($test_name);
     $this->runCount = 0;
     $this->failureCount = 0;
     $this->errorCount = 0;
     $this->timer = new Timer();
     $this->timer->start();
 }
开发者ID:altesien,项目名称:FinalProject,代码行数:9,代码来源:SimpleTestResultFormatter.php

示例6: paintCaseStart

 public function paintCaseStart($testName)
 {
     parent::paintCaseStart($testName);
     echo '<table cellspacing="0" cellpadding="0">', "\n";
     echo '    <tr>', "\n";
     echo '        <td>', "\n";
     echo '            <p class="test_heading">', $testName, '</p>', "\n";
     echo '            <table cellspacing="0" class="test_output">', "\n";
     echo '                <tr>', "\n";
     echo '                    <th>Result</td>', "\n";
     echo '                    <th nowrap="nowrap">Test Case</td>', "\n";
     echo '                    <th>Message</td>', "\n";
     echo '                </tr>', "\n";
     flush();
 }
开发者ID:PublicityPort,项目名称:OpenCATS,代码行数:15,代码来源:CATSTestReporter.php

示例7: paintCaseStart

 /**
  *  テストケース開始
  *
  *  @access public
  *  @param string   $test_name  テスト名称
  */
 function paintCaseStart($test_name)
 {
     parent::paintCaseStart($test_name);
     $this->report[] = array('type' => 'CaseStart', 'test_name' => $test_name);
 }
开发者ID:hiroki-namekawa,项目名称:test-upr,代码行数:11,代码来源:Ethna_UnitTestReporter.php

示例8: run

 /**
  *    Uses reflection to run every method within itself
  *    starting with the string "test".
  *    @param SimpleReporter $reporter    Current test reporter.
  *    @access public
  */
 function run(&$reporter)
 {
     $reporter->paintCaseStart($this->getLabel());
     $methods = get_class_methods(get_class($this));
     foreach ($methods as $method) {
         if (!$this->_isTest($method)) {
             continue;
         }
         if ($this->_isConstructor($method)) {
             continue;
         }
         $reporter->paintMethodStart($method);
         $this->_reporter =& $this->_createRunner($reporter);
         $this->_reporter->invoke($this, $method);
         $reporter->paintMethodEnd($method);
     }
     $reporter->paintCaseEnd($this->getLabel());
     return $reporter->getStatus();
 }
开发者ID:BackupTheBerlios,项目名称:limb-svn,代码行数:25,代码来源:simple_test.php

示例9: run

 /**
  *    Uses reflection to run every method within itself
  *    starting with the string "test".
  *    @param SimpleReporter $reporter    Current test reporter.
  *    @access public
  */
 function run(&$reporter)
 {
     $reporter->paintCaseStart($this->getLabel());
     $methods = get_class_methods(get_class($this));
     foreach ($methods as $method) {
         if (strtolower(substr($method, 0, 4)) != "test") {
             continue;
         }
         if (is_a($this, strtolower($method))) {
             continue;
         }
         $reporter->paintMethodStart($method);
         $this->_reporter =& $this->_createRunner($reporter);
         $this->_reporter->invoke($this, $method);
         $reporter->paintMethodEnd($method);
     }
     $reporter->paintCaseEnd($this->getLabel());
     return $reporter->getStatus();
 }
开发者ID:BackupTheBerlios,项目名称:limb-svn,代码行数:25,代码来源:simple_test.php

示例10: paintCaseStart

 function paintCaseStart($test_name)
 {
     print "\n {$test_name}\n";
     return parent::paintCaseStart($test_name);
 }
开发者ID:riaf,项目名称:pastit,代码行数:5,代码来源:TextDetailReporter.php

示例11: paintCaseStart

 public function paintCaseStart($test_case)
 {
     parent::paintCaseStart($test_case);
     $this->results[] = array('name' => $test_case, 'methods' => array());
 }
开发者ID:lubosdz,项目名称:simpletest-visual-gui,代码行数:5,代码来源:SimpleHtmlReporter.php

示例12: run

 /**
  *    Uses reflection to run every method within itself
  *    starting with the string "test" unless a method
  *    is specified.
  *    @param SimpleReporter $reporter    Current test reporter.
  *    @access public
  */
 function run(&$reporter)
 {
     SimpleTest::setCurrent($this);
     $reporter->paintCaseStart($this->getLabel());
     $this->_runner = $this->_createRunner($reporter);
     $this->_runner->run();
     $this->_runner = false;
     $reporter->paintCaseEnd($this->getLabel());
     return $reporter->getStatus();
 }
开发者ID:emma5021,项目名称:toba,代码行数:17,代码来源:test_case.php

示例13: paintCaseStart

 function paintCaseStart($test_name)
 {
     $this->buffer_case = "\n {$test_name}\n";
     $this->buffer_case_displayed = false;
     return parent::paintCaseStart($test_name);
 }
开发者ID:nterray,项目名称:tuleap,代码行数:6,代码来源:TestsPluginReporter.class.php

示例14: paintCaseStart

 /**
  * @param string $testName
  */
 public function paintCaseStart($testName)
 {
     parent::paintCaseStart($testName);
     $this->junitXMLWriter->startTestSuite($testName, $this->suite->countTestsInTestCase(\SimpleTest::getContext()->getTest()));
     $this->caseStarted = true;
 }
开发者ID:rsky,项目名称:stagehand-testrunner,代码行数:9,代码来源:JUnitXMLReporter.php

示例15: paintCaseStart

 /**
  * @param string $testName
  */
 public function paintCaseStart($testName)
 {
     parent::paintCaseStart($testName);
     $this->xmlWriter->startTestSuite($testName, $this->suite->countTestsInTestCase(SimpleTest::getContext()->getTest()));
 }
开发者ID:kumatch,项目名称:stagehand-testrunner,代码行数:8,代码来源:JUnitXMLReporter.php


注:本文中的SimpleReporter::paintCaseStart方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。