()
| 274 | } |
| 275 | |
| 276 | @Test |
| 277 | public void disconnectZKInterrupted() throws Exception { |
| 278 | Mockito.doThrow(new InterruptedException("Interrupted")).when(zk).close(); |
| 279 | zk_client.getDeferredRoot(); |
| 280 | zk_client.disconnectZK(); |
| 281 | verify(zk).close(); |
| 282 | assertNull(Whitebox.getInternalState(zk_client, "zk")); |
| 283 | } |
| 284 | |
| 285 | @Test (expected = RuntimeException.class) |
| 286 | public void disconnectZKUnexpected() throws Exception { |
nothing calls this directly
no test coverage detected