Esempio n. 1
0
  /** Test of toString method, of class OrderDirection. */
  @Test
  public void testToString() {
    Direction b = Direction.LONG;
    Direction s = Direction.SHORT;

    assertEquals("long", b.toString());
    assertEquals("long", b.getTitle());
    assertEquals("short", s.toString());
    assertEquals("short", s.getTitle());
  }
Esempio n. 2
0
 @Test
 public void test() {
   assertEquals(Direction.LONG, Direction.valueOf("LONG"));
   assertEquals(Direction.SHORT, Direction.valueOf("SHORT"));
   assertEquals(Direction.LONG, Direction.valueOf(Direction.LONG.name()));
 }