You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@velocity.apache.org by Christopher Schultz <ch...@christopherschultz.net> on 2020/12/14 17:10:47 UTC

[tools] Errors running 2.0.x branch unit tests in trunk

All,

I realize that 2.0 is a little long in the tooth, but I haven't yet 
moved to 3.0 (I still need Struts support) and so I'm working with that 
for the time being.

$ svn checkout 
http://svn.apache.org/repos/asf/velocity/tools/branches/2.0.x 
velocity-tools-2.0.x

$ cd velocity-tools-2.0.x

$ mvn package

This generates a lot of errors running the unit tests. Looking at 
README.txt says to use ant. Okay:

$ ant
    [...]
do-http-m2-download:
       [get] Getting: 
http://www.ibiblio.org/maven2/commons-collections/commons-collections/3.2/commons-collections-3.2.jar
    [...]
       [get] Can't get 
http://www.ibiblio.org/maven2/commons-collections/commons-collections/3.2/commons-collections-3.2.jar 
to velocity-tools-2.0.x/lib/commons-collections-3.2.jar

BUILD FAILED

Okay, this is a bit old. Let's adjust some version numbers and the 
primary download base URL.

And a bunch of ant properties and dependencies. In order to get "ant" to 
build successfully, I needed to apply this patch:

$ svn diff
Index: build.properties
===================================================================
--- build.properties	(revision 1884424)
+++ build.properties	(working copy)
@@ -121,8 +121,10 @@
  # We download directly from the ibiblio maven repository
  #
  #repo.m1.url=http://www.ibiblio.org/maven
-repo.m1.url=http://mirrors.ibiblio.org/pub/mirrors/maven2
-repo.m2.url=http://www.ibiblio.org/maven2
+#repo.m1.url=http://mirrors.ibiblio.org/pub/mirrors/maven2
+#repo.m2.url=http://www.ibiblio.org/maven2
+repo.m1.url=https://repo1.maven.org/maven2
+repo.m2.url=https://repo1.maven.org/maven2

  # Skip or force downloading of dependencies
  skip.jar.loading= false
@@ -131,22 +133,22 @@
  # Jars to be downloaded for compilation
  #
  jar.antlr.version= 2.7.2
-jar.commons-beanutils.version= 1.7.0
+jar.commons-beanutils.version= 1.9.4
  jar.commons-chain.version= 1.1
-jar.commons-collections.version= 3.2
-jar.commons-digester.version= 1.8
-jar.commons-lang.version= 2.2
-jar.commons-logging.version= 1.1
-jar.commons-validator.version= 1.3.1
+jar.commons-collections.version= 3.2.2
+jar.commons-digester.version= 1.8.1
+jar.commons-lang.version= 2.6
+jar.commons-logging.version= 1.1.1
+jar.commons-validator.version= 1.4.1
  jar.dom4j.version= 1.6.1
-jar.jaxen.version= 1.1-beta-6
+jar.jaxen.version= 1.1
  jar.oro.version= 2.0.8
  jar.servletapi.version= 2.3
  jar.sslext.version = 1.2-0
-jar.struts-core.version = 1.3.8
-jar.struts-taglib.version = 1.3.8
-jar.struts-tiles.version = 1.3.8
-jar.velocity.version= 1.6.4
+jar.struts-core.version = 1.3.10
+jar.struts-taglib.version = 1.3.10
+jar.struts-tiles.version = 1.3.10
+jar.velocity.version= 1.7

  # Jars to be downloaded for building documentation
  #
Index: build.xml
===================================================================
--- build.xml	(revision 1884424)
+++ build.xml	(working copy)
@@ -453,6 +453,7 @@
    <!-- Build all example applications -->
    <target name="examples" depends="jar.view,jar.struts,prepare.examples"
            description="Compiles and jars all example applications.">
+    <ant antfile="${basedir}/download.xml" target="full-download" />
      <ant antfile="${basedir}/examples.xml" target="build-examples" />
    </target>

Index: download.xml
===================================================================
--- download.xml	(revision 1884424)
+++ download.xml	(working copy)
@@ -149,6 +149,7 @@

    <target name="do-http-test-m1-download" unless="skip-download">
      <!-- set download.path if not set previously -->
+    <mkdir dir="${test.lib.dir}" />
      <property name="download.path" value="${download.groupId}/jars" />
      <setproxy proxyhost="${proxy.host}" proxyport="${proxy.port}"/>
      <get 
src="${repo.m1.url}/${download.path}/${download.artifactId}-${download.version}.jar"

Does all of that look okay?

I tried checking-out the "2.x" branch, but literally nothing works in 
there. It looks like that was something Claude tried and then gave up on.

There are also some test failures.

Any objections to me committing the above changes to the old branch? 
Then maybe investigating and fixing the unit test errors?

-chris

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@velocity.apache.org
For additional commands, e-mail: dev-help@velocity.apache.org