public ResultMatcher isArray ( ) { return new AbstractResultMatcher ( path , configuration ) { public void doMatch ( Object actual ) { isPresent ( actual ) ; Node node = getNode ( actual ) ; if ( node . getNodeType ( ) != ARRAY ) { failOnType ( node , "an array" ) ; } } } ; }
Fails if the selected JSON is not an Array or is not present .