예제 #1
0
 @Test
 public void testGetIntegerProperty() throws JTFException {
   // int databuf_size=1024
   Integer expected = 1024;
   Integer actual = sampleJTFCommand.getIntegerProperty(JTFCommand.DATABUF_SIZE, true);
   assertEquals(expected, actual);
 }
예제 #2
0
 @Test
 public void testGetLongProperty() throws JTFException {
   // long databuf_size=1024
   Long expected = 1024L;
   Long actual = sampleJTFCommand.getLongProperty(JTFCommand.DATABUF_SIZE, true);
   assertEquals(expected, actual);
 }
예제 #3
0
 @Test
 public void testGetIntegerPropertyWithNull() throws JTFException {
   Integer expected = null;
   Integer actual = sampleJTFCommand.getIntegerProperty(JTFCommand.WRITETHRU, false);
   // assertNull(actual);
   assertEquals(expected, actual);
 }
예제 #4
0
  @Test
  public void testGetStringProperty() throws JTFException {
    // cname=fdfcontainer
    String expected = "fdfcontainer";
    String actual = sampleJTFCommand.getStringProperty("cname", true);

    assertEquals(expected, actual);
  }
예제 #5
0
  @Test
  public void testGetBooleanProperty() throws JTFException {
    // keep_read
    Boolean expected = Boolean.TRUE;
    Boolean actual = sampleJTFCommand.getBooleanProperty(JTFCommand.KEEP_READ, false);

    assertEquals(expected, actual);
  }
예제 #6
0
 @Test
 public void testGetLongPropertyWithDefault() throws JTFException {
   // KEY_LEN_DEFAULT_VALUE = 1;
   Long expected = 1L;
   Long actual =
       sampleJTFCommand.getLongProperty(
           JTFCommand.KEY_LEN, false, (long) JTFCommand.KEY_LEN_DEFAULT_VALUE);
   assertEquals(expected, actual);
 }
예제 #7
0
 @Test
 public void testGetIntegerPropertyWithDefault() throws JTFException {
   // KEY_LEN_DEFAULT_VALUE = 1;
   Integer expected = 1;
   Integer actual =
       sampleJTFCommand.getIntegerProperty(
           JTFCommand.KEY_LEN, false, JTFCommand.KEY_LEN_DEFAULT_VALUE);
   assertEquals(expected, actual);
 }
예제 #8
0
  @Test
  public void testGetStringPropertyWithDefault() throws JTFException {
    // String DURABILITY_LEVEL_DEFAULT_VALUE = "ZS_DURABILITY_PERIODIC";
    String expected = "ZS_DURABILITY_PERIODIC";
    String actual =
        sampleJTFCommand.getStringProperty(
            JTFCommand.DURABILITY_LEVEL, false, JTFCommand.DURABILITY_LEVEL_DEFAULT_VALUE);

    assertEquals(expected, actual);
  }
예제 #9
0
 @Test(expected = JTFException.class)
 public void testGetIntegerPropertyThrowException() throws JTFException {
   sampleJTFCommand.getIntegerProperty(JTFCommand.DURABILITY_LEVEL, true);
 }
예제 #10
0
 @Test
 public void testGetBooleanPropertyWithNull() throws JTFException {
   Boolean expected = null;
   Boolean actual = sampleJTFCommand.getBooleanProperty(JTFCommand.FIFO_MODE, false);
   assertEquals(expected, actual);
 }