Пример #1
0
  public void testSetAndGet() {
    IntegerField i = new IntegerField();

    i.set(123);

    assertTrue(123 == i.get());
  }
Пример #2
0
  public void testMods() {
    IntegerField i = new IntegerField(0);
    assertEquals("foo integer", i.getDefinition("foo"));

    i = new IntegerField(17);
    assertEquals("foo integer", i.getDefinition("foo"));

    i = new IntegerField(10);
    assertEquals("foo integer(10)", i.getDefinition("foo"));
  }
Пример #3
0
  public void testDefauls() {
    IntegerField i = new IntegerField();

    assertEquals("foo integer", i.getDefinition("foo"));
    assertTrue(0 == i.get());
  }