comparison cake/tests/groups/no_cross_contamination.group.php @ 0:261e66bd5a0c

hg init
author Shoshi TAMAKI <shoshi@cr.ie.u-ryukyu.ac.jp>
date Sun, 24 Jul 2011 21:08:31 +0900
parents
children
comparison
equal deleted inserted replaced
-1:000000000000 0:261e66bd5a0c
1 <?php
2 /**
3 * NoCrossContaminationGroupTest file
4 *
5 * PHP versions 4 and 5
6 *
7 * CakePHP(tm) Tests <http://book.cakephp.org/view/1196/Testing>
8 * Copyright 2005-2010, Cake Software Foundation, Inc. (http://cakefoundation.org)
9 *
10 * Licensed under The Open Group Test Suite License
11 * Redistributions of files must retain the above copyright notice.
12 *
13 * @copyright Copyright 2005-2010, Cake Software Foundation, Inc. (http://cakefoundation.org)
14 * @link http://book.cakephp.org/view/1196/Testing CakePHP(tm) Tests
15 * @package cake
16 * @subpackage cake.tests.groups
17 * @since CakePHP(tm) v 1.2.0.4206
18 * @license http://www.opensource.org/licenses/opengroup.php The Open Group Test Suite License
19 */
20
21 /**
22 * NoCrossContaminationGroupTest class
23 *
24 * This test group will run all tests
25 * that are proper isolated to be run in sequence
26 * without affected each other
27 *
28 * @package cake
29 * @subpackage cake.tests.groups
30 */
31 class NoCrossContaminationGroupTest extends TestSuite {
32
33 /**
34 * label property
35 *
36 * @var string
37 * @access public
38 */
39 var $label = 'No Cross Contamination';
40
41 /**
42 * blacklist property
43 *
44 * @var string
45 * @access public
46 */
47 var $blacklist = array('cake_test_case.test.php', 'object.test.php');
48
49 /**
50 * NoCrossContaminationGroupTest method
51 *
52 * @access public
53 * @return void
54 */
55 function NoCrossContaminationGroupTest() {
56 App::import('Core', 'Folder');
57
58 $Folder = new Folder(CORE_TEST_CASES);
59
60 foreach ($Folder->findRecursive('.*\.test\.php', true) as $file) {
61 if (in_array(basename($file), $this->blacklist)) {
62 continue;
63 }
64 TestManager::addTestFile($this, $file);
65 }
66 }
67 }