Hi everybody,
I have a bug fix to the mantis tool and some changes to the controls build file
that I'd like to get committed. I've attached the output of "svn diff" as
diff.txt. I also have a new milton jar to commit. I don't want to send the jar
out to avoid an email bounce - so whoever would like to help me out, can you
contact me directly and I'll send it to you?
thanx!
Jamie Zyskowski
Index: controls/test/infra/mantis/mantis.jar
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream
Index:
controls/test/tools/mantis/src/org/apache/beehive/mantis/MantisFactory.java
===================================================================
--- controls/test/tools/mantis/src/org/apache/beehive/mantis/MantisFactory.java
(revision 36817)
+++ controls/test/tools/mantis/src/org/apache/beehive/mantis/MantisFactory.java
(working copy)
@@ -120,7 +120,10 @@
}
System.out.println("config="+configurl);
- System.out.println("num processor(s) initialized="+processors.size());
+ if(processors.contains(null))
+ System.out.println("ERROR: unable to instantiate and
initialize processor(s)");
+ else
+ System.out.println("num processor(s) initialized="+processors.size());
// create a composite of processors to return
AnnotationProcessors util = new AnnotationProcessors();
@@ -178,9 +181,14 @@
// instantiate the specified processors
try
{
- Class definition = Class.forName(p_procname);
+ System.out.println("INFO: ready to instantiate
processor class: "+p_procname);
+ // FIX: in win32 a ClassNotFoundException would be
thrown w/out a call to trim()
+ Class definition = Class.forName(p_procname.trim());
AbstractMantisProcessor proc = (AbstractMantisProcessor)
definition.newInstance();
+ //System.out.println("INFO: successfully instantiated
processor class: "+p_procname);
+ //System.out.println("INFO: ready to initialize
processor class: "+p_procname);
proc.init(p_atds,p_env);
+ System.out.println("INFO: successfully instantiated and
initialized processor class: "+p_procname);
return (AnnotationProcessor) proc;
}
catch(ClassNotFoundException cnfe)
Index: controls/test/tools/mantis/mantis.xml
===================================================================
--- controls/test/tools/mantis/mantis.xml (revision 36817)
+++ controls/test/tools/mantis/mantis.xml (working copy)
@@ -14,8 +14,8 @@
<property
file="${os.BEEHIVE_HOME}/controls/test/common/path.properties"/>
<!-- mantis properties -->
- <property name="mantis.root" value="${basedir}"/>
- <property name="mantis.jar" value="${mantis.root}/deploy/mantis.jar"/>
+ <property name="mantis.root" value="."/>
+ <property name="mantis.local.deploy.jar"
value="${mantis.root}/deploy/mantis.jar"/>
<property name="src.dir" value="${mantis.root}/src"/>
<property name="mantis.build.dir" value="${mantis.root}/build"/>
<property name="mantis.srcgen.dir" value="${mantis.root}/srcgen"/>
@@ -30,7 +30,7 @@
<!-- CLASSPATHS -->
<!--************-->
<path id="mantis.run.classpath">
- <pathelement path="${mantis.jar}"/>
+ <pathelement path="${mantis.local.deploy.jar}"/>
<pathelement path="${tchschema.jar}"/>
<pathelement path="${mantis.xbean.jar}"/>
<pathelement path="${ant.jar}"/>
Index: controls/test/build.xml
===================================================================
--- controls/test/build.xml (revision 36817)
+++ controls/test/build.xml (working copy)
@@ -173,7 +173,7 @@
<!-- =============================================== -->
- <!-- stuff below this is stuff i added -->
+ <!-- TCH and Mantis targets for running tests -->
<!-- =============================================== -->
<property name="junit.src.dir" value="${basedir}/src/units"/>
@@ -183,7 +183,22 @@
classpathref="tch.run.classpath"/>
<echo message="milton.jar: ${milton.jar}"/>
-
+
+ <target name="run-all">
+ <property name="tch.test.names"
value="org-apache-beehive-controls-test*.*"/>
+ <antcall target="run"/>
+ </target>
+
+ <target name="run-java">
+ <property name="tch.test.names"
value="org-apache-beehive-controls-test-java*.*"/>
+ <antcall target="run"/>
+ </target>
+
+ <target name="run-jpf">
+ <property name="tch.test.names"
value="org-apache-beehive-controls-test-jpf*.*"/>
+ <antcall target="run"/>
+ </target>
+
<target name="run" depends="mantis">
<gethostname/> <!-- set ${hostname} -->
@@ -191,24 +206,25 @@
<property name="test.hostname" value="${hostname}" />
<property name="test.hostname.port" value="8080" /> <!-- tomcat
default port -->
<property name="test-suite" value="${mantis.srcgen.dir}/root.xml"/>
- <property name="tch.base-logfile-name" value="tch"/>
+ <property name="tch.base-logfile-name"
value="tch"/>
- <tch tchHome="${tch.home}"
- testfile="${test-suite}"
- fork="true"
- classpathref="tch.run.classpath"
- failureproperty="run.failed">
+ <tch tchHome="${tch.home}"
+ testfile="${test-suite}"
+ fork="true"
+ classpathref="tch.run.classpath"
+ failureproperty="run.failed">
- <arg value="-emacs"/>
- <property name="tch.replication.entry-point" value="ant -f
${controls.test.dir}/build.xml run"/>
- <sysproperty key="TEST_HOSTNAME" value="${test.hostname}" />
- <sysproperty key="TEST_HOSTNAME_PORT" value="${test.hostname.port}"
/>
+ <arg value="-emacs"/>
+ <property name="tch.replication.entry-point"
value="ant -f ${controls.test.dir}/build.xml run"/>
+ <property name="tch.test-names"
value="${tch.test.names}"/>
+ <sysproperty
key="TEST_HOSTNAME" value="${test.hostname}" />
+ <sysproperty
key="TEST_HOSTNAME_PORT" value="${test.hostname.port}" />
- </tch>
+ </tch>
- <ant antfile="${controls.test.infra.dir}/tch/runtime/build.xml"
target="generate-html-log" dir="${basedir}">
- <property name="gtlf.file"
value="${basedir}/${tch.base-logfile-name}.xml"/>
- <property name="output.file"
value="${basedir}/${tch.base-logfile-name}.html"/>
+ <ant
antfile="${controls.test.infra.dir}/tch/runtime/build.xml"
target="generate-html-log" dir="${basedir}">
+ <property name="gtlf.file"
value="${basedir}/${tch.base-logfile-name}.xml"/>
+ <property name="output.file"
value="${basedir}/${tch.base-logfile-name}.html"/>
</ant>
</target>
@@ -251,6 +267,8 @@
classpath="${mantis.run.classpath}"
logdir="${mantis.log.dir}"
config="${mantis.config}"
+ processor="org.apache.beehive.mantis.TchProcessor"
+ timeout="10000"
aptcommand="${os.JAVA_HOME}/bin/apt"
/>
</target>