()
| 629 | } |
| 630 | |
| 631 | @Test |
| 632 | public void processResultRootBad() throws Exception { |
| 633 | final ZKCallback cb = zk_client.new ZKCallback(); |
| 634 | final byte[] data = "127.0.0.1".getBytes(CHARSET); |
| 635 | cb.processResult(Code.OK.intValue(), "/hbase/root-region-server", null, |
| 636 | data, stat); |
| 637 | verifyPrivate(client, never()).invoke("newClient", "127.0.0.1", 50511); |
| 638 | verifyPrivate(zk_client, never()).invoke("connectZK"); |
| 639 | verifyPrivate(zk_client, never()).invoke("disconnectZK"); |
| 640 | verifyPrivate(zk_client).invoke("retryGetRootRegionLater"); |
| 641 | verify(client).newTimeout((TimerTask)any(), anyLong()); |
| 642 | assertEquals(Byte.valueOf("1"), |
| 643 | (Byte)Whitebox.getInternalState(cb, "found_root")); |
| 644 | assertEquals(Byte.valueOf("0"), |
| 645 | (Byte)Whitebox.getInternalState(cb, "found_meta")); |
| 646 | } |
| 647 | |
| 648 | @Test |
| 649 | public void processResultRootCallWaiter() throws Exception { |
nothing calls this directly
no test coverage detected