Package com.opengamma.integration.tool.portfolio.xml

Examples of com.opengamma.integration.tool.portfolio.xml.SchemaVersion


    new SchemaVersion(".1");
  }

  @Test(expectedExceptions = IllegalArgumentException.class)
  public void testDigitsOnlyIsNotAllowed() {
    new SchemaVersion("1");
  }
View Full Code Here


  }

  @Test
  public void testEquality() {

    SchemaVersion sv1 = new SchemaVersion("3.4");
    SchemaVersion sv2 = new SchemaVersion("3.4");
    assertEquals(sv1, sv2);
  }
View Full Code Here

  }

  @Test
  public void testMajorOverridesMinor() {

    SchemaVersion sv1 = new SchemaVersion("3.4");
    SchemaVersion sv2 = new SchemaVersion("4.1");
    assertTrue(sv1.compareTo(sv2) < 0);
  }
View Full Code Here

  }

  @Test
  public void testMinorUsedIfMajorAreSame() {

    SchemaVersion sv1 = new SchemaVersion("3.4");
    SchemaVersion sv2 = new SchemaVersion("3.5");
    assertTrue(sv1.compareTo(sv2) < 0);
  }
View Full Code Here

  }

  @Test
  public void testIdenticalCompareSame() {

    SchemaVersion sv1 = new SchemaVersion("3.4");
    SchemaVersion sv2 = new SchemaVersion("3.4");
    assertTrue(sv1.compareTo(sv2) == 0);
  }
View Full Code Here

  }

  @Test
  public void testLeadingZeroesAreIgnoredForOutput() {

    SchemaVersion sv = new SchemaVersion("003.00004");
    assertEquals(sv.toString(), "3.4");
  }
View Full Code Here

  }

  @Test
  public void testLeadingZeroesAreIgnoredForEquality() {

    SchemaVersion sv1 = new SchemaVersion("003.00004");
    SchemaVersion sv2 = new SchemaVersion("3.4");
    assertEquals(sv1, sv2);
  }
View Full Code Here

TOP

Related Classes of com.opengamma.integration.tool.portfolio.xml.SchemaVersion

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.