@Test
public void test_getServiceDef_byId() throws Exception {

	// if service store returns null or throws an exception then service is deemed invalid
	when(_store.getServiceDef(1L)).thenReturn(null);
	when(_store.getServiceDef(2L)).thenThrow(new Exception());
	RangerServiceDef serviceDef = mock(RangerServiceDef.class);
	when(_store.getServiceDef(3L)).thenReturn(serviceDef);
	
	Assert.assertNull(_validator.getServiceDef(1L));
	Assert.assertNull(_validator.getServiceDef(2L));
	Assert.assertTrue(_validator.getServiceDef(3L) != null);
}