.openStream(),
"UTF-8" );
parser.parseBatchRequest();
BatchRequestDsml batchReq = parser.getBatchRequest();
assertNotNull( batchReq );
assertFalse( batchReq.isStoringRequests() );
assertTrue( batchReq.getRequests().isEmpty() );
SearchRequest searchRequest = ( SearchRequest ) parser.getNextRequest();
assertTrue( searchRequest.getTypesOnly() );
// assert again that the batch request object is not storing requests
assertTrue( batchReq.getRequests().isEmpty() );
searchRequest = ( SearchRequest ) parser.getNextRequest();
assertFalse( searchRequest.getTypesOnly() );
assertNull( parser.getNextRequest() );
// assert again that the batch request object is not storing requests
assertTrue( batchReq.getRequests().isEmpty() );
assertNotNull( batchReq.getCurrentRequest() );
}