@Test(expected = IllegalStateException.class)
public void testThrowIllegalStateExceptionIfNodeNotFoundInDiscoCache() {

    GridKernalContext ctx = mock(GridKernalContext.class);
    when(ctx.config()).thenReturn(new IgniteConfiguration());
    when(ctx.discovery()).thenReturn(mock(GridDiscoveryManager.class));
    GridSecurityProcessor secPrc = mock(GridSecurityProcessor.class);
    IgniteSecurityProcessor ignSecPrc = new IgniteSecurityProcessor(ctx, secPrc);
    ignSecPrc.withContext(UUID.randomUUID());
}