use of org.apache.ranger.entity.XXContextEnricherDef in project ranger by apache.
the class TestRangerServiceDefServiceBase method test14populateRangerContextEnricherDefToXXnullValue.
@Test
public void test14populateRangerContextEnricherDefToXXnullValue() {
RangerContextEnricherDef rangerContextEnricherDefObj = null;
XXContextEnricherDef contextEnricherDefObj = null;
XXServiceDef serviceDefObj = null;
Mockito.when(restErrorUtil.createRESTException("RangerServiceDef cannot be null.", MessageEnums.DATA_NOT_FOUND)).thenThrow(new WebApplicationException());
thrown.expect(WebApplicationException.class);
XXContextEnricherDef dbContextEnricherDef = rangerServiceDefService.populateRangerContextEnricherDefToXX(rangerContextEnricherDefObj, contextEnricherDefObj, serviceDefObj, 1);
Assert.assertNull(dbContextEnricherDef);
}
Aggregations