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

Examples of com.opengamma.integration.tool.portfolio.xml.FilesystemPortfolioSchemaLocator.lookupSchema()


  }

  @Test
  public void testNoSchemaFoundInEmptyDirectory() throws IOException {
    FilesystemPortfolioSchemaLocator locator = new FilesystemPortfolioSchemaLocator(createEmptySchemaLocation());
    assertNull(locator.lookupSchema(new SchemaVersion("1.0")));
  }

  @Test
  public void testMatchingSchemaFoundInDirectory() throws IOException {
    FilesystemPortfolioSchemaLocator locator = new FilesystemPortfolioSchemaLocator(
View Full Code Here


  @Test
  public void testMatchingSchemaFoundInDirectory() throws IOException {
    FilesystemPortfolioSchemaLocator locator = new FilesystemPortfolioSchemaLocator(
        createSchemaLocationWithVersions("1.0", "1.1", "2.0"));
    assertNotNull(locator.lookupSchema(new SchemaVersion("1.0")));
    assertNotNull(locator.lookupSchema(new SchemaVersion("1.1")));
    assertNotNull(locator.lookupSchema(new SchemaVersion("2.0")));
  }

  @Test
View Full Code Here

  @Test
  public void testMatchingSchemaFoundInDirectory() throws IOException {
    FilesystemPortfolioSchemaLocator locator = new FilesystemPortfolioSchemaLocator(
        createSchemaLocationWithVersions("1.0", "1.1", "2.0"));
    assertNotNull(locator.lookupSchema(new SchemaVersion("1.0")));
    assertNotNull(locator.lookupSchema(new SchemaVersion("1.1")));
    assertNotNull(locator.lookupSchema(new SchemaVersion("2.0")));
  }

  @Test
  public void testNoSchemaFoundInDirectory() throws IOException {
View Full Code Here

  public void testMatchingSchemaFoundInDirectory() throws IOException {
    FilesystemPortfolioSchemaLocator locator = new FilesystemPortfolioSchemaLocator(
        createSchemaLocationWithVersions("1.0", "1.1", "2.0"));
    assertNotNull(locator.lookupSchema(new SchemaVersion("1.0")));
    assertNotNull(locator.lookupSchema(new SchemaVersion("1.1")));
    assertNotNull(locator.lookupSchema(new SchemaVersion("2.0")));
  }

  @Test
  public void testNoSchemaFoundInDirectory() throws IOException {
    FilesystemPortfolioSchemaLocator locator = new FilesystemPortfolioSchemaLocator(
View Full Code Here

  @Test
  public void testNoSchemaFoundInDirectory() throws IOException {
    FilesystemPortfolioSchemaLocator locator = new FilesystemPortfolioSchemaLocator(
        createSchemaLocationWithVersions("1.0", "1.1", "2.0"));
    assertNull(locator.lookupSchema(new SchemaVersion("1.2")));
    assertNull(locator.lookupSchema(new SchemaVersion("2.1")));
    assertNull(locator.lookupSchema(new SchemaVersion("3.0")));
  }

  private File createSchemaLocationWithVersions(String... versions) throws IOException {
View Full Code Here

  @Test
  public void testNoSchemaFoundInDirectory() throws IOException {
    FilesystemPortfolioSchemaLocator locator = new FilesystemPortfolioSchemaLocator(
        createSchemaLocationWithVersions("1.0", "1.1", "2.0"));
    assertNull(locator.lookupSchema(new SchemaVersion("1.2")));
    assertNull(locator.lookupSchema(new SchemaVersion("2.1")));
    assertNull(locator.lookupSchema(new SchemaVersion("3.0")));
  }

  private File createSchemaLocationWithVersions(String... versions) throws IOException {
    File dir = Files.createTempDirectory("portfolio-schemas").toFile();
View Full Code Here

  public void testNoSchemaFoundInDirectory() throws IOException {
    FilesystemPortfolioSchemaLocator locator = new FilesystemPortfolioSchemaLocator(
        createSchemaLocationWithVersions("1.0", "1.1", "2.0"));
    assertNull(locator.lookupSchema(new SchemaVersion("1.2")));
    assertNull(locator.lookupSchema(new SchemaVersion("2.1")));
    assertNull(locator.lookupSchema(new SchemaVersion("3.0")));
  }

  private File createSchemaLocationWithVersions(String... versions) throws IOException {
    File dir = Files.createTempDirectory("portfolio-schemas").toFile();
    dir.deleteOnExit();
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.