Exemplo n.º 1
0
  @Test
  public void testGranularityFromStateCol() {
    Granularity myGranularity = serDes.granularityFromStateCol("metrics_full,1,okay");
    Assert.assertNotNull(myGranularity);
    Assert.assertEquals(myGranularity, Granularity.FULL);

    myGranularity = serDes.granularityFromStateCol("FULL");
    Assert.assertNull(myGranularity);
  }
Exemplo n.º 2
0
 @Test
 public void testStateFromStateCode() {
   Assert.assertEquals(UpdateStamp.State.Active, serDes.stateFromCode("foo"));
   Assert.assertEquals(UpdateStamp.State.Active, serDes.stateFromCode("A"));
   Assert.assertEquals(UpdateStamp.State.Rolled, serDes.stateFromCode("X"));
 }
Exemplo n.º 3
0
 @Test
 public void testStateFromStateCol() {
   Assert.assertEquals("okay", serDes.stateCodeFromStateCol("metrics_full,1,okay"));
 }
Exemplo n.º 4
0
 @Test
 public void testSlotFromStateCol() {
   Assert.assertEquals(1, serDes.slotFromStateCol("metrics_full,1,okay"));
 }