incubator-depot-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From aj...@apache.org
Subject svn commit: rev 10430 - in incubator/depot/trunk/update: . src/java src/resources/test/org/apache/depot src/resources/test/org/apache/depot/update src/resources/test/org/apache/ruper src/test/org/apache/depot/update/ant/task src/test/org/apache/depot/update/files src/test/org/apache/depot/update/util/security src/test/org/apache/depot/update/util/select src/test/org/apache/depot/update/util/select/logic src/test/org/apache/depot/update/util/xml
Date Thu, 29 Apr 2004 20:25:47 GMT
Author: ajack
Date: Thu Apr 29 13:25:47 2004
New Revision: 10430

Added:
   incubator/depot/trunk/update/src/resources/test/org/apache/depot/
   incubator/depot/trunk/update/src/resources/test/org/apache/depot/update/
Removed:
   incubator/depot/trunk/update/src/resources/test/org/apache/ruper/
Modified:
   incubator/depot/trunk/update/.svnignore
   incubator/depot/trunk/update/src/java/depot-update-antlib.xml
   incubator/depot/trunk/update/src/test/org/apache/depot/update/ant/task/AntTasksTests.java
   incubator/depot/trunk/update/src/test/org/apache/depot/update/ant/task/RepositoryToolTaskTests.java
   incubator/depot/trunk/update/src/test/org/apache/depot/update/ant/task/SynchronizeTaskTests.java
   incubator/depot/trunk/update/src/test/org/apache/depot/update/ant/task/reposync.xml
   incubator/depot/trunk/update/src/test/org/apache/depot/update/ant/task/repotool.xml
   incubator/depot/trunk/update/src/test/org/apache/depot/update/files/DefaultResourceAnalyzerTests.java
   incubator/depot/trunk/update/src/test/org/apache/depot/update/util/security/HashCodeManagerTest.java
   incubator/depot/trunk/update/src/test/org/apache/depot/update/util/select/CompositeSelectorTests.java
   incubator/depot/trunk/update/src/test/org/apache/depot/update/util/select/logic/NotSelectorTests.java
   incubator/depot/trunk/update/src/test/org/apache/depot/update/util/xml/XMLParserTests.java
Log:
Workign through tests...


Modified: incubator/depot/trunk/update/.svnignore
==============================================================================
--- incubator/depot/trunk/update/.svnignore	(original)
+++ incubator/depot/trunk/update/.svnignore	Thu Apr 29 13:25:47 2004
@@ -2,3 +2,4 @@
 dist
 .project
 .classpath
+helloworld*jar

Modified: incubator/depot/trunk/update/src/java/depot-update-antlib.xml
==============================================================================
--- incubator/depot/trunk/update/src/java/depot-update-antlib.xml	(original)
+++ incubator/depot/trunk/update/src/java/depot-update-antlib.xml	Thu Apr 29 13:25:47 2004
@@ -15,8 +15,10 @@
 -->
 <antlib>
     <typedef name="cachedset" classname="org.apache.depot.update.ant.CachedResourceSet"/>
+    
     <typedef name="resource" classname="org.apache.depot.update.ant.ResourceElement"/>
     <typedef name="repository" classname="org.apache.depot.update.ant.RepositoryElement"/>
-    <typedef name="repotool" classname="org.apache.depot.update.ant.task.RepositoryToolTask"/>
-    <typedef name="reposync" classname="org.apache.depot.update.ant.task.SynchronizeTask"/>
+    
+    <taskdef name="repotool" classname="org.apache.depot.update.ant.task.RepositoryToolTask"/>
+    <taskdef name="reposync" classname="org.apache.depot.update.ant.task.SynchronizeTask"/>
 </antlib>

Modified: incubator/depot/trunk/update/src/test/org/apache/depot/update/ant/task/AntTasksTests.java
==============================================================================
--- incubator/depot/trunk/update/src/test/org/apache/depot/update/ant/task/AntTasksTests.java
(original)
+++ incubator/depot/trunk/update/src/test/org/apache/depot/update/ant/task/AntTasksTests.java
Thu Apr 29 13:25:47 2004
@@ -39,7 +39,7 @@
 
 	public void setUp() throws Exception {
     	super.setUp();
-		configureProject("update/src/test/org/apache/depot/update/ant/task/anttasks.xml");
+		configureProject("src/test/org/apache/depot/update/ant/task/anttasks.xml");
 	}
 
 	public void test1() {

Modified: incubator/depot/trunk/update/src/test/org/apache/depot/update/ant/task/RepositoryToolTaskTests.java
==============================================================================
--- incubator/depot/trunk/update/src/test/org/apache/depot/update/ant/task/RepositoryToolTaskTests.java
(original)
+++ incubator/depot/trunk/update/src/test/org/apache/depot/update/ant/task/RepositoryToolTaskTests.java
Thu Apr 29 13:25:47 2004
@@ -38,7 +38,7 @@
 	}
 
 	public void setUp() {
-		configureProject("version/src/test/org/apache/depot/update/ant/task/repotool.xml");
+		configureProject("src/test/org/apache/depot/update/ant/task/repotool.xml");
 	}
 
 	public void test1() {

Modified: incubator/depot/trunk/update/src/test/org/apache/depot/update/ant/task/SynchronizeTaskTests.java
==============================================================================
--- incubator/depot/trunk/update/src/test/org/apache/depot/update/ant/task/SynchronizeTaskTests.java
(original)
+++ incubator/depot/trunk/update/src/test/org/apache/depot/update/ant/task/SynchronizeTaskTests.java
Thu Apr 29 13:25:47 2004
@@ -41,7 +41,7 @@
 	}
 
 	public void setUp() {
-		configureProject("version/src/test/org/apache/depot/update/ant/task/reposync.xml");
+		configureProject("src/test/org/apache/depot/update/ant/task/reposync.xml");
 	}
 
 	public void test1() {

Modified: incubator/depot/trunk/update/src/test/org/apache/depot/update/ant/task/reposync.xml
==============================================================================
--- incubator/depot/trunk/update/src/test/org/apache/depot/update/ant/task/reposync.xml	(original)
+++ incubator/depot/trunk/update/src/test/org/apache/depot/update/ant/task/reposync.xml	Thu
Apr 29 13:25:47 2004
@@ -1,6 +1,6 @@
 <?xml version="1.0"?>
 <project name="ruper-synchronize-test" basedir="." default="all">
-	<taskdef resource="apache-ruper-tasks.xml"/>	
+	<taskdef resource="depot-update-antlib.xml"/>	
 		
 	<target name="test1">
 		<reposync group="test" />

Modified: incubator/depot/trunk/update/src/test/org/apache/depot/update/ant/task/repotool.xml
==============================================================================
--- incubator/depot/trunk/update/src/test/org/apache/depot/update/ant/task/repotool.xml	(original)
+++ incubator/depot/trunk/update/src/test/org/apache/depot/update/ant/task/repotool.xml	Thu
Apr 29 13:25:47 2004
@@ -1,6 +1,6 @@
 <?xml version="1.0"?>
 <project name="ruper-repotool-test" basedir="." default="all">
-	<taskdef resource="apache-ruper-tasks.xml"/>	
+	<taskdef resource="depot-update-antlib.xml"/>	
 		
 	<target name="test1">
 		<repotool />

Modified: incubator/depot/trunk/update/src/test/org/apache/depot/update/files/DefaultResourceAnalyzerTests.java
==============================================================================
--- incubator/depot/trunk/update/src/test/org/apache/depot/update/files/DefaultResourceAnalyzerTests.java
(original)
+++ incubator/depot/trunk/update/src/test/org/apache/depot/update/files/DefaultResourceAnalyzerTests.java
Thu Apr 29 13:25:47 2004
@@ -33,8 +33,8 @@
 public class DefaultResourceAnalyzerTests extends TestCase {
 
 	private DefaultResourceFilenameAnalyzer m_analyzer = null;
-	private VirtualResourceLocator m_http = null;
-	private VirtualResourceLocator m_file = null;
+	//private VirtualResourceLocator m_http = null;
+	//private VirtualResourceLocator m_file = null;
 
 	public DefaultResourceAnalyzerTests(String name) {
 		super(name);

Modified: incubator/depot/trunk/update/src/test/org/apache/depot/update/util/security/HashCodeManagerTest.java
==============================================================================
--- incubator/depot/trunk/update/src/test/org/apache/depot/update/util/security/HashCodeManagerTest.java
(original)
+++ incubator/depot/trunk/update/src/test/org/apache/depot/update/util/security/HashCodeManagerTest.java
Thu Apr 29 13:25:47 2004
@@ -65,6 +65,9 @@
         URL urlHashFile = clazzLoader.getResource("org/apache/depot/update/util/security/test.txt");
         URL urlMetaFile = clazzLoader.getResource("org/apache/depot/update/util/security/test.txt.md5");
 
+        assertNotNull("Loaded HashFile", urlHashFile);
+        assertNotNull("Loaded MetaFile", urlMetaFile);
+
         File hashFile = new File(urlHashFile.getPath());
         File metaFile = new File(urlMetaFile.getPath());
                 
@@ -132,6 +135,8 @@
         ClassLoader clazzLoader = this.getClass().getClassLoader();
         URL urlMetaFile = clazzLoader.getResource("org/apache/depot/update/util/security/test.txt.md5");
 
+        assertNotNull("Loaded MetaFile", urlMetaFile);
+        
         File metaFile = new File(urlMetaFile.getPath());
 
 		byte[] digest = HashCodeManager.readHashFromFile(metaFile);

Modified: incubator/depot/trunk/update/src/test/org/apache/depot/update/util/select/CompositeSelectorTests.java
==============================================================================
--- incubator/depot/trunk/update/src/test/org/apache/depot/update/util/select/CompositeSelectorTests.java
(original)
+++ incubator/depot/trunk/update/src/test/org/apache/depot/update/util/select/CompositeSelectorTests.java
Thu Apr 29 13:25:47 2004
@@ -64,7 +64,7 @@
         try{
             m_selector.addSelector( null );
             fail("Should not be able to add null selector");
-        } catch( NullPointerException e ) {
+        } catch( IllegalArgumentException e ) {
             // expect this
         }
     }

Modified: incubator/depot/trunk/update/src/test/org/apache/depot/update/util/select/logic/NotSelectorTests.java
==============================================================================
--- incubator/depot/trunk/update/src/test/org/apache/depot/update/util/select/logic/NotSelectorTests.java
(original)
+++ incubator/depot/trunk/update/src/test/org/apache/depot/update/util/select/logic/NotSelectorTests.java
Thu Apr 29 13:25:47 2004
@@ -32,7 +32,7 @@
         try{
             m_not.setSelector( null );
             fail("Should throw exception if we try to set null selector");
-        } catch( NullPointerException e ) {
+        } catch( IllegalArgumentException e ) {
             //expect this
         }
     }

Modified: incubator/depot/trunk/update/src/test/org/apache/depot/update/util/xml/XMLParserTests.java
==============================================================================
--- incubator/depot/trunk/update/src/test/org/apache/depot/update/util/xml/XMLParserTests.java
(original)
+++ incubator/depot/trunk/update/src/test/org/apache/depot/update/util/xml/XMLParserTests.java
Thu Apr 29 13:25:47 2004
@@ -31,15 +31,15 @@
 
 	public void testXMLParse() throws Exception {
 		XMLEntryTable xmlEntryTable = new XMLEntryTable();
-		xmlEntryTable.put("parent", "org.apache.ruper.util.xml.TestParent");
-		xmlEntryTable.put("child", "org.apache.ruper.util.xml.TestChild");
+		xmlEntryTable.put("parent", "org.apache.depot.update.util.xml.TestParent");
+		xmlEntryTable.put("child", "org.apache.depot.update.util.xml.TestChild");
 
 		ClassLoaderContext helper = new ClassLoaderContext(xmlEntryTable);
 		
 		XMLParser parser = new XMLParser(xmlEntryTable, helper);
 		XMLContext xmlContext =
 			parser.parse(
-				new File("src/java/test/org/apache/depot/update/util/xml/test.xml"));
+				new File("src/test/org/apache/depot/update/util/xml/test.xml"));
 
 		HashMap map = xmlContext.getCreatedTagObjects();
 		assertNotNull("Has Parent Object", map.get("parent"));

Mime
View raw message