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


PHP UnitTestCase::after方法代碼示例

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


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

示例1: after

 /**
  * Decorates SimpleTest's implementation to auto-validate mock objects.
  */
 public function after($method)
 {
     try {
         $this->_mockery()->assertIsSatisfied();
     } catch (Yay_NotSatisfiedException $e) {
         $this->fail($e->getMessage());
     }
     $this->_mockery = null;
     return parent::after($method);
 }
開發者ID:abouthalf,項目名稱:archies-recipes,代碼行數:13,代碼來源:SwiftUnitTestCase.php

示例2: after

 /**
  * Announces the end of a test.
  *
  * @param string $method Test method just finished.
  * @return void
  * @access public
  */
 function after($method)
 {
     $isTestMethod = !in_array(strtolower($method), array('start', 'end'));
     if (isset($this->_fixtures) && isset($this->db) && $isTestMethod) {
         foreach ($this->_fixtures as $fixture) {
             $fixture->truncate($this->db);
         }
         $this->__truncated = true;
     } else {
         $this->__truncated = false;
     }
     if (!in_array(strtolower($method), $this->methods)) {
         $this->endTest($method);
     }
     $this->_should_skip = false;
     parent::after($method);
 }
開發者ID:cls1991,項目名稱:ryzomcore,代碼行數:24,代碼來源:cake_test_case.php

示例3: after

 /**
  * Announces the end of a test.
  *
  * @param string $method Test method just finished.
  *
  * @access public
  */
 function after($method)
 {
     if (isset($this->_fixtures) && isset($this->db) && !in_array(low($method), array('start', 'end'))) {
         foreach ($this->_fixtures as $fixture) {
             $query = $fixture->truncate();
             if (isset($query) && $query !== false) {
                 $this->db->_execute($query);
             }
         }
     }
     if (!in_array(low($method), $this->methods)) {
         $this->endTest($method);
     }
     parent::after($method);
 }
開發者ID:rhencke,項目名稱:mozilla-cvs-history,代碼行數:22,代碼來源:cake_test_case.php

示例4: after

 /**
  *    Announces the end of the test. Includes private clean up.
  *    @param string $method    Test method just finished.
  *    @access public
  */
 function after($method)
 {
     parent::after($this->cleanCamelCase($method));
 }
開發者ID:nterray,項目名稱:tuleap,代碼行數:9,代碼來源:TuleapTestCase.class.php

示例5: after

 /**
  *    Announces the end of the test. Includes private clean up.
  *    @param string $method    Test method just finished.
  *    @access public
  */
 function after($method)
 {
     $this->unsetBrowser();
     parent::after($method);
 }
開發者ID:GerHobbelt,項目名稱:simpletest,代碼行數:10,代碼來源:web_tester.php

示例6: after

 /**
  * Announces the end of a test.
  *
  * @param string $method Test method just finished.
  *
  * @access public
  */
 function after($method)
 {
     if (isset($this->_fixtures) && isset($this->db) && !in_array(low($method), array('start', 'end'))) {
         foreach ($this->_fixtures as $fixture) {
             $this->db->truncate($fixture->table);
         }
         $this->__truncated = true;
     } else {
         $this->__truncated = false;
     }
     if (!in_array(low($method), $this->methods)) {
         $this->endTest($method);
     }
     parent::after($method);
 }
開發者ID:kaz0636,項目名稱:openflp,代碼行數:22,代碼來源:cake_test_case.php


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