diff --git a/core/model/Hierarchy.php b/core/model/Hierarchy.php index f45fc6b7e..4e5b8a444 100755 --- a/core/model/Hierarchy.php +++ b/core/model/Hierarchy.php @@ -668,6 +668,12 @@ class Hierarchy extends DataObjectDecorator { $this->_cache_allChildren = null; $this->_cache_numChildren = null; } + + function reset() { + self::$marked = array(); + self::$expanded = array(); + self::$treeOpened = array(); + } } ?> diff --git a/dev/SapphireTest.php b/dev/SapphireTest.php index 915203040..97fe7e68e 100755 --- a/dev/SapphireTest.php +++ b/dev/SapphireTest.php @@ -71,6 +71,7 @@ class SapphireTest extends PHPUnit_Framework_TestCase { Versioned::reset(); DataObject::reset(); SiteTree::reset(); + Hierarchy::reset(); Controller::curr()->setSession(new Session(array())); $className = get_class($this);