KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > openlaszlo > xml > internal > XMLUtils_Test


1 /* ****************************************************************************
2  * XMLUtils_Test.java
3  * ****************************************************************************/

4
5 /* J_LZ_COPYRIGHT_BEGIN *******************************************************
6 * Copyright 2001-2004 Laszlo Systems, Inc. All Rights Reserved. *
7 * Use is subject to license terms. *
8 * J_LZ_COPYRIGHT_END *********************************************************/

9
10 package org.openlaszlo.xml.internal;
11 import java.io.*;
12 import java.util.*;
13 import junit.framework.*;
14
15 /*
16  * junit.awtui.TestRunner
17  * junit.swingui.TestRunner
18  * junit.textui.TestRunner
19  *
20  * java junit.textui.TestRunner org.openlaszlo.utils.XMLUtils_Test
21  *
22  * @author Oliver Steele
23  */

24
25 public class XMLUtils_Test extends TestCase {
26     public XMLUtils_Test(String JavaDoc name) {
27         super(name);
28     }
29
30     public void setUp() {
31     }
32
33     public void testPathnameFunctions() {
34         assertTrue(XMLUtils.isURL("http:foo"));
35         assertTrue(XMLUtils.isURL("file:foo"));
36         assertTrue(XMLUtils.isURL("https:foo"));
37         assertTrue(XMLUtils.isURL("soap:foo"));
38         assertTrue(XMLUtils.isURL("ftp:foo"));
39         assertTrue(!XMLUtils.isURL("a/b"));
40         assertTrue(!XMLUtils.isURL("/a/b"));
41         assertTrue(!XMLUtils.isURL("c:/a/b"));
42     }
43 }
44
Popular Tags