From 1e099a93460f8a9b550d8e523a93706a2cf3892f Mon Sep 17 00:00:00 2001 From: Daniel Convissor Date: Tue, 10 Jan 2012 00:53:42 +0000 Subject: [PATCH] Do not echo stuff, these are unit tests. git-svn-id: http://svn.php.net/repository/pear/packages/DB_NestedSet/trunk@321982 c90b9560-bf6c-de11-be94-00142212c4b1 --- tests/DB/NestedSet/TestCase.php | 10 ++++++---- tests/DB_NestedSet_APITest.php | 22 +++++++++++----------- 2 files changed, 17 insertions(+), 15 deletions(-) diff --git a/tests/DB/NestedSet/TestCase.php b/tests/DB/NestedSet/TestCase.php index bca5950..0c7c5d7 100644 --- a/tests/DB/NestedSet/TestCase.php +++ b/tests/DB/NestedSet/TestCase.php @@ -108,14 +108,14 @@ function _moveTree__Across($branches, $mvt, $nodecount) { if ($p['id'] != $mnode['parent']) { // // - echo "\n
\n";
+                        // echo "\n
\n";
                         print_r($p);
-                        echo "\n
\n"; + // echo "\n
\n"; //
// - echo "\n
\n";
+                        // echo "\n
\n";
                         print_r($mnode);
-                        echo "\n
\n"; + // echo "\n
\n"; //
//
} @@ -518,6 +518,8 @@ function _traverseChildRelations($relationTree, $nid, $deep = false, $init = fal } function _indentTree($tree) { + return; + echo "\n"; foreach($tree AS $nid => $node) { printf('%s %02d-%02d [%02d|%02d|%02d] | %s (%s)', diff --git a/tests/DB_NestedSet_APITest.php b/tests/DB_NestedSet_APITest.php index 02913ee..3e324ec 100644 --- a/tests/DB_NestedSet_APITest.php +++ b/tests/DB_NestedSet_APITest.php @@ -7,7 +7,7 @@ function test_sortMethods() { // Rootnodes - echo ""; + // echo ""; $values['STRNA'] = 'Skireisen'; $skireisen = $this->_NeSe->createRootNode($values, false, true); @@ -34,36 +34,36 @@ function test_sortMethods() { $meransen = $this->_NeSe->createSubNode($italien, $values); - echo "DEFAULT\n"; + // echo "DEFAULT\n"; $this->_NeSe->setSortMode(NESE_SORT_LEVEL); $allnodes_default = $this->_NeSe->getAllNodes(true); $this->_indentTree($allnodes_default); - echo "BY NAME\n"; + // echo "BY NAME\n"; $this->_NeSe->setSortMode(NESE_SORT_LEVEL); $this->_NeSe->secondarySort = 'STRNA'; $allnodes_byname = $this->_NeSe->getAllNodes(true); $this->_indentTree($allnodes_byname); - echo "PREORDER\n"; + // echo "PREORDER\n"; $this->_NeSe->setSortMode(NESE_SORT_PREORDER); $this->_NeSe->secondarySort = 'STREH'; $allnodes_preorder = $this->_NeSe->getAllNodes(true); $this->_indentTree($allnodes_preorder); - echo "BY NAME PREORDER\n"; + // echo "BY NAME PREORDER\n"; $this->_NeSe->setSortMode(NESE_SORT_PREORDER); $this->_NeSe->secondarySort = 'STRNA'; $allnodes_byname_pre = $this->_NeSe->getAllNodes(true); $this->_indentTree($allnodes_byname_pre); - echo "BY NAME PREORDER getSubBranch\n"; + // echo "BY NAME PREORDER getSubBranch\n"; $this->_NeSe->setSortMode(NESE_SORT_PREORDER); $this->_NeSe->secondarySort = 'STRNA'; $allnodes_preorder = $this->_NeSe->getSubBranch($oesterreich, true); $this->_indentTree($allnodes_preorder); - echo "BY NAME PREORDER getSubBranch empty subbranch\n"; + // echo "BY NAME PREORDER getSubBranch empty subbranch\n"; $this->_NeSe->setSortMode(NESE_SORT_PREORDER); $this->_NeSe->secondarySort = 'STRNA'; $allnodes_preorder = $this->_NeSe->getSubBranch($grindelwald, true); @@ -71,18 +71,18 @@ function test_sortMethods() { - echo "TRYING getBranch()\n"; + // echo "TRYING getBranch()\n"; $atbranch = $this->_NeSe->getBranch($oesterreich, true); $this->_indentTree($atbranch); - echo "TRYING getChildren()\n"; + // echo "TRYING getChildren()\n"; $atbranch = $this->_NeSe->getChildren($oesterreich, true); $this->_indentTree($atbranch); - echo "TRYING getSubBranch()\n"; + // echo "TRYING getSubBranch()\n"; $atbranch = $this->_NeSe->getSubBranch($skireisen, true); $this->_indentTree($atbranch); - echo ""; + // echo ""; } function test_convertModel() {