()
| 426 | } |
| 427 | |
| 428 | @Test (expected = NoSuchUniqueId.class) |
| 429 | public void parseFromColumnWithUIDMetaNSU() throws Exception { |
| 430 | class ErrBack implements Callback<Object, Exception> { |
| 431 | @Override |
| 432 | public Object call(Exception e) throws Exception { |
| 433 | Throwable ex = e; |
| 434 | while (ex.getClass().equals(DeferredGroupException.class)) { |
| 435 | ex = ex.getCause(); |
| 436 | } |
| 437 | throw (Exception)ex; |
| 438 | } |
| 439 | } |
| 440 | |
| 441 | final KeyValue column = mock(KeyValue.class); |
| 442 | when(column.key()).thenReturn(new byte[] { 0, 0, 1, 0, 0, 1, 0, 0, 2 }); |
| 443 | when(column.value()).thenReturn(("{\"tsuid\":\"000001000001000002\",\"" + |
| 444 | "description\":\"Description\",\"notes\":\"Notes\",\"created\":1328140800," + |
| 445 | "\"custom\":null,\"units\":\"\",\"retention\":42,\"max\":1.0,\"min\":" + |
| 446 | "\"NaN\",\"displayName\":\"Display\",\"dataType\":\"Data\"}") |
| 447 | .getBytes(MockBase.ASCII())); |
| 448 | TSMeta.parseFromColumn(tsdb, column, true).addErrback(new ErrBack()) |
| 449 | .joinUninterruptibly(); |
| 450 | } |
| 451 | } |
nothing calls this directly
no test coverage detected