Skip to content

Commit cae7792

Browse files
committed
Added root node rename test
1 parent 3095c00 commit cae7792

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

tests/10_Writing/MoveMethodsTest.php

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,17 @@ protected function setUp()
2020
parent::setUp();
2121
}
2222

23+
public function testNodeRenameRoot()
24+
{
25+
$root = $this->session->getRootNode();
26+
$newNode = $root->addNode('foobar');
27+
$newNode->rename('barfoo');
28+
$this->session->save();
29+
$this->renewSession();
30+
$node = $this->session->getNode('/barfoo');
31+
$this->assertNotNull($node);
32+
}
33+
2334
public function testNodeRename()
2435
{
2536
$first = $this->node->getNode('firstNode');

0 commit comments

Comments
 (0)