@Test
public void test21applyPolicy() throws Exception {

	HttpServletRequest request = Mockito.mock(HttpServletRequest.class);
	RangerPolicy rangerPolicy = rangerPolicy();
	Mockito.when(serviceREST.applyPolicy(rangerPolicy, request)).thenReturn(rangerPolicy);
	RangerPolicy dbRangerPolicy = publicAPIsv2.applyPolicy(rangerPolicy, request);
	Assert.assertNotNull(dbRangerPolicy);
	Assert.assertEquals(dbRangerPolicy, rangerPolicy);
	Assert.assertEquals(dbRangerPolicy.getId(),
			rangerPolicy.getId());
	Assert.assertEquals(dbRangerPolicy.getName(),
			rangerPolicy.getName());
	Mockito.verify(serviceREST).applyPolicy(rangerPolicy, request);
}