From 241bda262aa92ad379462dea28cd33d7d1aede70 Mon Sep 17 00:00:00 2001 From: gwoo Date: Mon, 4 Feb 2008 16:59:52 +0000 Subject: [PATCH] updating test manager to show "all tests" when there are no app groups git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@6433 3807eeeb-6ff5-0310-8944-8be069107fe0 --- cake/tests/lib/test_manager.php | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/cake/tests/lib/test_manager.php b/cake/tests/lib/test_manager.php index 06c74d2f0..699af482f 100644 --- a/cake/tests/lib/test_manager.php +++ b/cake/tests/lib/test_manager.php @@ -267,14 +267,10 @@ class TextTestManager extends TestManager { $manager =& new TextTestManager(); $groupTests =& $manager->_getTestGroupList($directory); - if (1 > count($groupTests)) { - $noGroups = "No test groups set up!\n"; - return $noGroups; - } $buffer = "Available test groups:\n"; $buffer .= $manager->getBaseURL() . "?group=all All tests<\n"; - foreach ($groupTests as $groupTest) { + foreach ((array)$groupTests as $groupTest) { $buffer .= "
  • " . $groupTest . "&output=txt"."
  • \n"; } return $buffer . "\n"; @@ -321,11 +317,6 @@ class HtmlTestManager extends TestManager { $manager =& new HtmlTestManager(); $groupTests =& $manager->_getTestGroupList($directory); - if (1 > count($groupTests)) { - $noGroupTests = "

    No test cases set up!

    "; - return $noGroupTests; - } - if (isset($_GET['app'])) { $buffer = "

    Available App Test Groups:

    \n\n";