1 7 8 package org.netbeans.modules.xml.retriever; 9 10 import junit.framework.*; 11 import java.io.IOException ; 12 import java.net.URI ; 13 import java.net.URISyntaxException ; 14 import java.net.UnknownHostException ; 15 import org.netbeans.modules.xml.retriever.catalog.Utilities; 16 import org.openide.filesystems.FileObject; 17 import org.openide.filesystems.FileUtil; 18 19 23 public class RetrieverTest extends TestCase { 24 25 public RetrieverTest(String testName) { 26 super(testName); 27 } 28 29 protected void setUp() throws Exception { 30 } 31 32 protected void tearDown() throws Exception { 33 } 34 35 public static Test suite() { 36 TestSuite suite = new TestSuite(RetrieverTest.class); 37 38 return suite; 39 } 40 41 44 public void testGetDefault() throws URISyntaxException , UnknownHostException , IOException { 45 System.out.println("getDefault"); 46 47 Retriever expResult = null; 48 Retriever result = Retriever.getDefault(); 49 60 } 61 62 65 public void testRelativize() throws Exception { 66 System.out.println("getDefault"); 67 URI masterURI = new URI ("A/B/C"); 68 URI slaveURI = new URI ("A/B/C/D/E"); 69 String result = Utilities.relativize(masterURI, slaveURI); 70 assert(result.equals("D/E")); 71 } 72 73 74 } 75 | Popular Tags |