"arg0"
).getPropertyPath().iterator();
//parameter 0
assertTrue( nodeIter.hasNext() );
Node nextNode = nodeIter.next();
assertNode( nextNode, methodName, ElementKind.METHOD, false, null, null );
MethodNode methodNode = nextNode.as( MethodNode.class );
assertNotNull( methodNode );
assertEquals(
methodNode.getParameterTypes(),
Arrays.<Class<?>>asList( String.class, Person.class, List.class )
);
assertTrue( nodeIter.hasNext() );
nextNode = nodeIter.next();
assertNode( nextNode, "arg0", ElementKind.PARAMETER, false, null, null );
ParameterNode parameterNode = nextNode.as( ParameterNode.class );
assertNotNull( parameterNode );
assertEquals( parameterNode.getParameterIndex(), 0 );
assertFalse( nodeIter.hasNext() );
//parameter 1
nodeIter = getConstraintViolationForParameter( constraintViolations, "arg1" ).getPropertyPath().iterator();
assertTrue( nodeIter.hasNext() );
assertNode( nodeIter.next(), methodName, ElementKind.METHOD, false, null, null );
assertTrue( nodeIter.hasNext() );
nextNode = nodeIter.next();
assertNode( nextNode, "arg1", ElementKind.PARAMETER, false, null, null );
parameterNode = nextNode.as( ParameterNode.class );
assertNotNull( parameterNode );
assertEquals( parameterNode.getParameterIndex(), 1 );
assertFalse( nodeIter.hasNext() );
}