[
https://issues.jboss.org/browse/SHRINKDESC-84?page=com.atlassian.jira.plu...
]
Andrew Rubinger commented on SHRINKDESC-84:
-------------------------------------------
Let's also add tests to ensure that the following methods are not acting in recursive
fashion:
getSingle
getOrCreate
removeChildren
removeChild
Node.get(Patterns) matches recursive down the whole tree
--------------------------------------------------------
Key: SHRINKDESC-84
URL:
https://issues.jboss.org/browse/SHRINKDESC-84
Project: ShrinkWrap Descriptors
Issue Type: Bug
Components: spi
Affects Versions: 1.1.0-alpha-3
Reporter: Aslak Knutsen
Priority: Critical
Fix For: 1.1.0-alpha-4
Node.get should only try to match the first level.
{code}
@Test
public void shouldNotMatchAChildsChildrenOnQuery()
{
// /root/child1/child2
Node root = new Node(ROOT_NAME)
.createChild(CHILD_1_NAME)
.createChild(CHILD_2_NAME).getRoot();
// this Assert fails
Assert.assertNull(root.get(CHILD_2_NAME));
}
{code}
--
This message is automatically generated by JIRA.
For more information on JIRA, see:
http://www.atlassian.com/software/jira