Package net.sf.jabref.export.layout.format

Examples of net.sf.jabref.export.layout.format.ResolvePDF


  public void tearDown() {
    super.tearDown();
  }

  public void testFormat() throws URISyntaxException {
    LayoutFormatter pdf = new ResolvePDF();

    assertEquals("", pdf.format(""));
   
    /*
     * Check one that will be found
     */
    String result = pdf.format("Organization Science\\HipKro03 - Hello.pdf");
    assertTrue(result.startsWith("file:/"));
   
    assertTrue(result.endsWith("/Organization%20Science/HipKro03%20-%20Hello.pdf"));
   
    // Should not contain a backslash:
    assertEquals(-1, result.indexOf('\\'));
   
    assertTrue(new File(new URI(result)).exists());
   
    /*
     * And one that is not to be found
     */
    result = pdf.format("Organization Science/Does not exist.pdf");
    assertEquals("Organization Science/Does not exist.pdf", result);
  }
View Full Code Here

TOP

Related Classes of net.sf.jabref.export.layout.format.ResolvePDF

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.