ant-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From maart...@apache.org
Subject svn commit: r750617 - in /ant/ivy/core/trunk/test: java/org/apache/ivy/ant/ repositories/IVY-1037/ repositories/IVY-1037/rep1/ repositories/IVY-1037/rep1/org/ repositories/IVY-1037/rep1/org/module/ repositories/IVY-1037/rep2/ repositories/IVY-1037/rep2...
Date Thu, 05 Mar 2009 21:54:27 GMT
Author: maartenc
Date: Thu Mar  5 21:54:26 2009
New Revision: 750617

URL: http://svn.apache.org/viewvc?rev=750617&view=rev
Log:
Added junit test for IVY-1037 (thanks to Martin Eigenbrodt)

Added:
    ant/ivy/core/trunk/test/repositories/IVY-1037/
    ant/ivy/core/trunk/test/repositories/IVY-1037/ivysettings.xml   (with props)
    ant/ivy/core/trunk/test/repositories/IVY-1037/rep1/
    ant/ivy/core/trunk/test/repositories/IVY-1037/rep1/org/
    ant/ivy/core/trunk/test/repositories/IVY-1037/rep1/org/module/
    ant/ivy/core/trunk/test/repositories/IVY-1037/rep1/org/module/ivy-1.xml   (with props)
    ant/ivy/core/trunk/test/repositories/IVY-1037/rep2/
    ant/ivy/core/trunk/test/repositories/IVY-1037/rep2/org/
    ant/ivy/core/trunk/test/repositories/IVY-1037/rep2/org/module/
    ant/ivy/core/trunk/test/repositories/IVY-1037/rep2/org/module/ivy-2.xml   (with props)
Modified:
    ant/ivy/core/trunk/test/java/org/apache/ivy/ant/IvyBuildNumberTest.java

Modified: ant/ivy/core/trunk/test/java/org/apache/ivy/ant/IvyBuildNumberTest.java
URL: http://svn.apache.org/viewvc/ant/ivy/core/trunk/test/java/org/apache/ivy/ant/IvyBuildNumberTest.java?rev=750617&r1=750616&r2=750617&view=diff
==============================================================================
--- ant/ivy/core/trunk/test/java/org/apache/ivy/ant/IvyBuildNumberTest.java (original)
+++ ant/ivy/core/trunk/test/java/org/apache/ivy/ant/IvyBuildNumberTest.java Thu Mar  5 21:54:26
2009
@@ -176,5 +176,20 @@
         assertEquals("0", buildNumber.getProject().getProperty("ivy.build.number"));
         assertEquals("1", buildNumber.getProject().getProperty("ivy.new.build.number"));
     }
+    
+    public void testChainResolver() throws Exception {
+        // IVY-1037
+        Project project = new Project();
+        project.setProperty("ivy.settings.file", "test/repositories/IVY-1037/ivysettings.xml");
+
+        buildNumber = new IvyBuildNumber();
+        buildNumber.setProject(project);
+        buildNumber.setOrganisation("org");
+        buildNumber.setModule("module");
+        buildNumber.setResolver("chain");
+        buildNumber.execute();
+        assertEquals("3", buildNumber.getProject().getProperty("ivy.new.revision"));
+    }
+
 
 }

Added: ant/ivy/core/trunk/test/repositories/IVY-1037/ivysettings.xml
URL: http://svn.apache.org/viewvc/ant/ivy/core/trunk/test/repositories/IVY-1037/ivysettings.xml?rev=750617&view=auto
==============================================================================
--- ant/ivy/core/trunk/test/repositories/IVY-1037/ivysettings.xml (added)
+++ ant/ivy/core/trunk/test/repositories/IVY-1037/ivysettings.xml Thu Mar  5 21:54:26 2009
@@ -0,0 +1,33 @@
+<!--
+   Licensed to the Apache Software Foundation (ASF) under one
+   or more contributor license agreements.  See the NOTICE file
+   distributed with this work for additional information
+   regarding copyright ownership.  The ASF licenses this file
+   to you under the Apache License, Version 2.0 (the
+   "License"); you may not use this file except in compliance
+   with the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing,
+   software distributed under the License is distributed on an
+   "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+   KIND, either express or implied.  See the License for the
+   specific language governing permissions and limitations
+   under the License.    
+-->
+<ivyconf>
+    <conf defaultResolver="chain"/>
+    <resolvers>
+        <chain name="chain" >
+            <filesystem name="rep1" >
+                <ivy pattern="${ivy.settings.dir}/rep1/[organisation]/[module]/ivy-[revision].xml"/>
+                <artifact pattern="${ivy.settings.dir}/rep1/[organisation]/[module]/[artifact]-[revision].[ext]"/>
+            </filesystem>
+            <filesystem name="rep2" >
+                <ivy pattern="${ivy.settings.dir}/rep2/[organisation]/[module]/ivy-[revision].xml"/>
+                <artifact pattern="${ivy.settings.dir}/rep2/[organisation]/[module]/[artifact]-[revision].[ext]"/>
+            </filesystem>
+        </chain>
+    </resolvers>
+</ivyconf>
\ No newline at end of file

Propchange: ant/ivy/core/trunk/test/repositories/IVY-1037/ivysettings.xml
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: ant/ivy/core/trunk/test/repositories/IVY-1037/rep1/org/module/ivy-1.xml
URL: http://svn.apache.org/viewvc/ant/ivy/core/trunk/test/repositories/IVY-1037/rep1/org/module/ivy-1.xml?rev=750617&view=auto
==============================================================================
--- ant/ivy/core/trunk/test/repositories/IVY-1037/rep1/org/module/ivy-1.xml (added)
+++ ant/ivy/core/trunk/test/repositories/IVY-1037/rep1/org/module/ivy-1.xml Thu Mar  5 21:54:26
2009
@@ -0,0 +1,22 @@
+<!--
+   Licensed to the Apache Software Foundation (ASF) under one
+   or more contributor license agreements.  See the NOTICE file
+   distributed with this work for additional information
+   regarding copyright ownership.  The ASF licenses this file
+   to you under the Apache License, Version 2.0 (the
+   "License"); you may not use this file except in compliance
+   with the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing,
+   software distributed under the License is distributed on an
+   "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+   KIND, either express or implied.  See the License for the
+   specific language governing permissions and limitations
+   under the License.    
+-->
+<ivy-module version="2.0">
+    <info organisation="org" module="module" revision="1" status="integration" publication="20090108103716"/>
+    <publications/>
+</ivy-module>

Propchange: ant/ivy/core/trunk/test/repositories/IVY-1037/rep1/org/module/ivy-1.xml
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: ant/ivy/core/trunk/test/repositories/IVY-1037/rep2/org/module/ivy-2.xml
URL: http://svn.apache.org/viewvc/ant/ivy/core/trunk/test/repositories/IVY-1037/rep2/org/module/ivy-2.xml?rev=750617&view=auto
==============================================================================
--- ant/ivy/core/trunk/test/repositories/IVY-1037/rep2/org/module/ivy-2.xml (added)
+++ ant/ivy/core/trunk/test/repositories/IVY-1037/rep2/org/module/ivy-2.xml Thu Mar  5 21:54:26
2009
@@ -0,0 +1,22 @@
+<!--
+   Licensed to the Apache Software Foundation (ASF) under one
+   or more contributor license agreements.  See the NOTICE file
+   distributed with this work for additional information
+   regarding copyright ownership.  The ASF licenses this file
+   to you under the Apache License, Version 2.0 (the
+   "License"); you may not use this file except in compliance
+   with the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing,
+   software distributed under the License is distributed on an
+   "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+   KIND, either express or implied.  See the License for the
+   specific language governing permissions and limitations
+   under the License.    
+-->
+<ivy-module version="2.0">
+    <info organisation="org" module="module" revision="2" status="integration" publication="20090108103716"/>
+    <publications/>
+</ivy-module>

Propchange: ant/ivy/core/trunk/test/repositories/IVY-1037/rep2/org/module/ivy-2.xml
------------------------------------------------------------------------------
    svn:mime-type = text/plain



Mime
View raw message