MCPcopy Create free account
hub / github.com/OpenTSDB/asynchbase / callbackWithTimeoutWithoutDeferred

Method callbackWithTimeoutWithoutDeferred

test/TestHBaseRpc.java:262–275  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

260 }
261
262 @Test
263 public void callbackWithTimeoutWithoutDeferred() throws Exception {
264 final GetRequest rpc = new GetRequest(TABLE, KEY, FAMILY);
265 rpc.attempt = 4;
266 final Timeout timeout_handle = mock(Timeout.class);
267 final Object response = new Object();
268 rpc.timeout_handle = timeout_handle;
269 assertFalse(rpc.hasDeferred());
270
271 rpc.callback(response);
272 assertEquals(4, rpc.attempt);
273 assertFalse(rpc.hasDeferred());
274 verify(timeout_handle).cancel();
275 }
276
277 @Test
278 public void timeout() throws Exception {

Callers

nothing calls this directly

Calls 2

hasDeferredMethod · 0.80
callbackMethod · 0.45

Tested by

no test coverage detected