コード例 #1
0
  @Test
  public void testGetNonExistentAggregate() {
    CBAggregate aggr = new CBAggregate("count", "dostrovsky");

    double result = aggr.get().toBlocking().single().getResult();

    LOG.log(Level.INFO, "value = {0}", result);

    assertEquals("" + 1.0, "" + result);
  }
コード例 #2
0
  @Test
  public void testGetAggregate() {

    CBAggregate aggr = new CBAggregate("count", "dmaier");
    aggr.setResult(5);
    aggr.create().toBlocking().single();

    double result = aggr.get().toBlocking().single().getResult();

    LOG.log(Level.INFO, "value = {0}", result);

    assertEquals("" + 5.0, "" + result);
  }