[ Index ]
 

Code source de SPIP Agora 1.4

Accédez au Source d'autres logiciels libresSoutenez Angelica Josefina !

title

Body

[fermer]

/Pear/DB/tests/NestedSet/ -> query.php (sommaire)

(pas de description)

Poids: 298 lignes (11 kb)
Inclus ou requis:0 fois
Référencé: 0 fois
Nécessite: 0 fichiers

Définit 1 class

tests_NestedSet_query:: (10 méthodes):
  test_getAllNodes()
  test_getRootNodes()
  test_getParents()
  test_getParent()
  test_getSiblings()
  test_isParent()
  test_getChildren()
  test_getBranch()
  test_getSubBranch()
  test_pickNode()


Classe: tests_NestedSet_query  - X-Ref

UnitTest
Query method tests

test_getAllNodes()   X-Ref
tests_NestedSet_common::test_getAllNodes()

Creates some nodes and verifies the result

return: bool True on completion

test_getRootNodes()   X-Ref
tests_NestedSet_common::test_getRootNodes()

Create 2 sets of rootnodes (ordered and mixed) and see if the result matches
getRootNodes()

return: bool True on completion

test_getParents()   X-Ref
tests_NestedSet_common::test_getParents()

Handcraft the parent tree using the relation tree from _createSubNode()
and compare it against getParents()

return: bool True on completion

test_getParent()   X-Ref
tests_NestedSet_common::test_getParent()

Build a simple tree run getParent() and compare it with the relation tree

return: bool True on completion

test_getSiblings()   X-Ref
Pas de description

test_isParent()   X-Ref
tests_NestedSet_common::isParent()

Create a tree, go trogh each node, fetch all children
and see if isParent() returns true

return: bool True on completion

test_getChildren()   X-Ref
tests_NestedSet_common::test_getChildren()

Create some children
The dirty work is done in _traverseChildren()
Here we only calc if the expected number of children returned matches
the count of getChildren()

return: bool True on completion

test_getBranch()   X-Ref
tests_NestedSet_common::test_getBranch()

If we only have one branch getAllNodes() has to eual getBranch()

return: bool True on completion

test_getSubBranch()   X-Ref
tests_NestedSet_common::test_getSubBranch()

Handcraft a sub branch using the relation tree from _createSubNode()
and compare it against getSubBranch()

return: bool True on completion

test_pickNode()   X-Ref
tests_NestedSet_common::test_pickNode()

Create some rootnodes and run pickNode() on it.

return: bool True on completion



Généré le : Sat Feb 24 14:40:03 2007 par Balluche grâce à PHPXref 0.7