ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From co...@apache.org
Subject cvs commit: jakarta-ant/src/testcases/org/apache/tools/ant/types DescriptionTest.java FilterSetTest.java
Date Thu, 30 Aug 2001 13:26:38 GMT
conor       01/08/30 06:26:38

  Modified:    .        WHATSNEW build.xml
               src/etc  junit-frames.xsl junit-noframes.xsl
               src/etc/testcases/taskdefs/optional/antlr antlr.xml
               src/etc/testcases/types filterset.xml
               src/main/org/apache/tools/ant AntClassLoader.java
                        DefaultLogger.java XmlLogger.java
               src/main/org/apache/tools/ant/taskdefs ExecuteOn.java
                        Javac.java Javadoc.java Manifest.java Property.java
                        XSLTProcess.java
               src/main/org/apache/tools/ant/taskdefs/compilers
                        DefaultCompilerAdapter.java
               src/main/org/apache/tools/ant/taskdefs/optional/ejb
                        BorlandDeploymentTool.java WLRun.java
               src/main/org/apache/tools/ant/taskdefs/optional/net FTP.java
               src/main/org/apache/tools/ant/taskdefs/rmic WLRmic.java
               src/main/org/apache/tools/ant/types CommandlineJava.java
                        Description.java
               src/testcases/org/apache/tools/ant/taskdefs
                        TaskdefsTest.java
               src/testcases/org/apache/tools/ant/taskdefs/optional
                        AbstractXSLTLiaisonTest.java
               src/testcases/org/apache/tools/ant/types FilterSetTest.java
  Added:       src/etc/testcases/types description1.xml description2.xml
                        description3.xml description4.xml
               src/testcases/org/apache/tools/ant/types
                        DescriptionTest.java
  Log:
  Merge in 1.4 src changes
  
  Revision  Changes    Path
  1.147     +11 -1     jakarta-ant/WHATSNEW
  
  Index: WHATSNEW
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/WHATSNEW,v
  retrieving revision 1.146
  retrieving revision 1.147
  diff -u -w -u -r1.146 -r1.147
  --- WHATSNEW	2001/08/18 15:02:35	1.146
  +++ WHATSNEW	2001/08/30 13:26:36	1.147
  @@ -36,7 +36,7 @@
     encoding attribute of the task and set it to UTF8 to get the old
     behavior.
   
  -* The <pvcs> task has been move to a package of its own.
  +* The <pvcs> task has been moved to a package of its own.
   
   * JUnitResultFormater has two additional methods that must be
     implemented by custom formatters.
  @@ -93,6 +93,16 @@
     </delete>
     will now remove "somedir" as well, unless there are still files left
     in it (matched by the default excludes).
  +  
  +* The copy task will now fail if the file to be copied is not found. 
  +
  +* Ant properties defined in properties files now behave the same way as 
  +  properties defined in the build file. In particular the $ character needs
  +  to be escaped in property values by doubling it to $$. So, to define a 
  +  property with the value $hello, you need to define it in a properties file
  +  as
  +    test.prop=$$hello
  +  This was not the case in Ant 1.3
   
   Other changes:
   --------------
  
  
  
  1.179     +11 -10    jakarta-ant/build.xml
  
  Index: build.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/build.xml,v
  retrieving revision 1.178
  retrieving revision 1.179
  diff -u -w -u -r1.178 -r1.179
  --- build.xml	2001/08/23 22:00:32	1.178
  +++ build.xml	2001/08/30 13:26:36	1.179
  @@ -161,6 +161,7 @@
       <available property="xalan.envcheck"
                  classname="org.apache.xalan.xslt.EnvironmentCheck"
                  classpathref="classpath" />
  +               
       <condition property="javamail.complete">
         <and>
           <available classname="javax.activation.DataHandler"
  @@ -180,6 +181,11 @@
       <tstamp>
         <format property="year" pattern="yyyy" />
       </tstamp>
  +    <filterset id="ant.filters">
  +      <filter token="VERSION" value="${version}" />
  +      <filter token="DATE" value="${TODAY}" />
  +      <filter token="TIME" value="${TSTAMP}" />
  +    </filterset>
     </target>
   
     <!-- 
  @@ -256,12 +262,7 @@
           <include name="**/version.txt" />
           <include name="**/defaultManifest.mf" />
         </fileset>
  -      <filterset>
  -        <filter token="VERSION" value="${version}" />
  -        <filter token="DATE" value="${TODAY}" />
  -        <filter token="TIME" value="${TSTAMP}" />
  -      </filterset>
  -      
  +      <filterset refid="ant.filters"/>
       </copy>
   
       <copy todir="${build.classes}/${optional.package}/junit/xsl">
  @@ -369,9 +370,9 @@
   
       <copy todir="${dist.lib}" file="${lib.dir}/optional/README"/>
       
  -    <copy todir="${dist.docs}"
  -          filtering="on">
  +    <copy todir="${dist.docs}">
         <fileset dir="${docs.dir}"/>
  +      <filterset refid="ant.filters"/>
       </copy>
   
       <copy todir="${dist.dir}">
  
  
  
  1.4       +130 -49   jakarta-ant/src/etc/junit-frames.xsl
  
  Index: junit-frames.xsl
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/etc/junit-frames.xsl,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -w -u -r1.3 -r1.4
  --- junit-frames.xsl	2001/08/18 14:59:38	1.3
  +++ junit-frames.xsl	2001/08/30 13:26:36	1.4
  @@ -118,54 +118,55 @@
   </html>
   </xsl:template>
   
  -
   <!-- this is the stylesheet css to use for nearly everything -->
   <xsl:template name="stylesheet.css">
   body {
   	font:normal 68% verdana,arial,helvetica;
   	color:#000000;
  +}
  +table tr td, table tr th {
  +    font-size: 68%;
  +}
  +table.details tr th{
  +	font-weight: bold;
  +	text-align:left;
  +	background:#a6caf0;
   }
  -td {
  -	font-size: 68%
  +table.details tr td{
  +	background:#eeeee0;
   }
  +
   p {
   	line-height:1.5em;
   	margin-top:0.5em; margin-bottom:1.0em;
   }
   h1 {
  -	margin: 0px 0px 5px;
  -	font: 165% verdana,arial,helvetica
  +	margin: 0px 0px 5px; font: 165% verdana,arial,helvetica
   }
   h2 {
  -	margin-top: 1em;
  -	margin-bottom: 0.5em;
  -	font: bold 125% verdana,arial,helvetica
  +	margin-top: 1em; margin-bottom: 0.5em; font: bold 125% verdana,arial,helvetica
   }
   h3 {
  -	margin-bottom: 0.5em;
  -	font: bold 115% verdana,arial,helvetica
  +	margin-bottom: 0.5em; font: bold 115% verdana,arial,helvetica
   }
   h4 {
  -	margin-bottom: 0.5em;
  -	font: bold 100% verdana,arial,helvetica
  +	margin-bottom: 0.5em; font: bold 100% verdana,arial,helvetica
   }
   h5 {
  -	margin-bottom: 0.5em;
  -	font: bold 100% verdana,arial,helvetica
  +	margin-bottom: 0.5em; font: bold 100% verdana,arial,helvetica
   }
   h6 {
  -	margin-bottom: 0.5em;
  -	font: bold 100% verdana,arial,helvetica
  +	margin-bottom: 0.5em; font: bold 100% verdana,arial,helvetica
   }
   .Error {
  -	font-weight:bold;
  -	color:red;
  +	font-weight:bold; color:red;
   }
   .Failure {
  -	font-weight:bold;
  -	color:purple;
  +	font-weight:bold; color:purple;
   }
  -
  +.Properties {
  +  text-align:right;
  +}
   </xsl:template>
   
   
  @@ -181,29 +182,87 @@
   			<xsl:call-template name="create.stylesheet.link">
   				<xsl:with-param name="package.name" select="$package.name"/>
   			</xsl:call-template>
  +      <script language="JavaScript">
  +        var TestCases = new Array();
  +        var cur;
  +        <xsl:apply-templates select="properties"/>
  +       </script>
  +       <script language="JavaScript"><![CDATA[
  +        function displayProperties (name) {
  +          var win = window.open('','JUnitSystemProperties','scrollbars=1,resizable=1');
  +          var doc = win.document.open();
  +          doc.write("<html><head><title>Properties of " + name + "</title>");
  +          doc.write("<style>")
  +          doc.write("body {font:normal 68% verdana,arial,helvetica;	color:#000000; }");
  +          doc.write("table tr td, table tr th { font-size: 68%; }");
  +          doc.write("table.properties { border-collapse:collapse; border-left:solid 1 #cccccc; border-top:solid 1 #cccccc; padding:5px; }");
  +          doc.write("table.properties th { text-align:left; border-right:solid 1 #cccccc; border-bottom:solid 1 #cccccc; background-color:#eeeeee; }");
  +          doc.write("table.properties td { font:normal; text-align:left; border-right:solid 1 #cccccc; border-bottom:solid 1 #cccccc; background-color:#fffffff; }");
  +          doc.write("h3 { margin-bottom: 0.5em; font: bold 115% verdana,arial,helvetica }");
  +          doc.write("</style>");
  +          doc.write("</head><body>");
  +          doc.write("<h3>Properties of " + name + "</h3>");
  +          doc.write("<div align=\"right\"><a href=\"javascript:window.close();\">Close</a></div>");
  +          doc.write("<table class='properties'>");
  +          doc.write("<tr><th>Name</th><th>Value</th></tr>");
  +          for (prop in TestCases[name]) {
  +            doc.write("<tr><th>" + prop + "</th><td>" + TestCases[name][prop] + "</td></tr>");
  +          }
  +          doc.write("</table>");
  +          doc.write("</body></html>");
  +          doc.close();
  +          win.focus();
  +        }
  +      ]]>  
  +      </script>
   		</head>
   		<body>
   			<xsl:call-template name="pageHeader"/>	
   			<h3>Class <xsl:if test="not($package.name = '')"><xsl:value-of select="$package.name"/>.</xsl:if><xsl:value-of select="@name"/></h3>
   
   			
  -			<table border="0" cellpadding="5" cellspacing="2" width="95%">
  +			<table class="details" border="0" cellpadding="5" cellspacing="2" width="95%">
   				<xsl:call-template name="testsuite.test.header"/>
   				<xsl:apply-templates select="." mode="print.test"/>
   			</table>
   	
   			<h2>Tests</h2>
   			<p>
  -			<table border="0" cellpadding="5" cellspacing="2" width="95%">
  -				<xsl:call-template name="testcase.test.header"/>
  +			<table class="details" border="0" cellpadding="5" cellspacing="2" width="95%">
  +			  <!--
  +			  test can even not be started at all (failure to load the class)
  +			  so report the error directly
  +			  -->
  +				<xsl:if test="./error">
  +					<tr class="Error">
  +						<td colspan="4"><xsl:apply-templates select="./error"/></td>
  +					</tr>
  +				</xsl:if>
   				<xsl:apply-templates select="./testcase" mode="print.test"/>
   			</table>
  -			
   			</p>
  +      <div class="Properties">
  +        <a>
  +          <xsl:attribute name="href">javascript:displayProperties('<xsl:value-of select="@package"/>.<xsl:value-of select="@name"/>');</xsl:attribute>
  +          Properties &gt;&gt;
  +        </a>
  +      </div>
   		</body>
   	</html>
   </xsl:template>
   
  +  <!--
  +   Write properties into a JavaScript data structure.
  +   This is based on the original idea by Erik Hatcher (erik@hatcher.net)
  +   -->
  +  <xsl:template match="properties">
  +    cur = TestCases['<xsl:value-of select="../@package"/>.<xsl:value-of select="../@name"/>'] = new Array();
  +  	<xsl:for-each select="property">
  +    <xsl:sort select="@name"/>
  +        cur['<xsl:value-of select="@name"/>'] = '<xsl:call-template name="JS-escape"><xsl:with-param name="string" select="@value"/></xsl:call-template>';
  +  	</xsl:for-each>
  +  </xsl:template>
  +
   
   <!-- ======================================================================
       This page is created for every package.
  @@ -340,15 +399,15 @@
   		<xsl:variable name="failureCount" select="sum(testsuite/@failures)"/>
   		<xsl:variable name="timeCount" select="sum(testsuite/@time)"/>
   		<xsl:variable name="successRate" select="($testCount - $failureCount - $errorCount) div $testCount"/>
  -		<table border="0" cellpadding="5" cellspacing="2" width="95%">
  -		<tr bgcolor="#A6CAF0" valign="top">
  -			<td><strong>Tests</strong></td>
  -			<td><strong>Failures</strong></td>
  -			<td><strong>Errors</strong></td>
  -			<td><strong>Success rate</strong></td>
  -			<td><strong>Time</strong></td>
  +		<table class="details" border="0" cellpadding="5" cellspacing="2" width="95%">
  +		<tr valign="top">
  +			<th>Tests</th>
  +			<th>Failures</th>
  +			<th>Errors</th>
  +			<th>Success rate</th>
  +			<th>Time</th>
   		</tr>
  -		<tr bgcolor="#EEEEE" valign="top">
  +		<tr valign="top">
   			<xsl:attribute name="class">
   				<xsl:choose>
   					<xsl:when test="$errorCount &gt; 0">Error</xsl:when>
  @@ -381,13 +440,13 @@
   		</table>
   		
   		<h2>Packages</h2>
  -		<table border="0" cellpadding="5" cellspacing="2" width="95%">
  +		<table class="details" border="0" cellpadding="5" cellspacing="2" width="95%">
   			<xsl:call-template name="testsuite.test.header"/>
   			<xsl:for-each select="testsuite[not(./@package = preceding-sibling::testsuite/@package)]">
   				<xsl:sort select="@package" order="ascending"/>
   				<!-- get the node set containing all testsuites that have the same package -->
   				<xsl:variable name="insamepackage" select="/testsuites/testsuite[./@package = current()/@package]"/>
  -				<tr bgcolor="#EEEEE" valign="top">
  +				<tr valign="top">
   					<!-- display a failure if there is any failure/error in the package -->
   					<xsl:attribute name="class">
   						<xsl:choose>
  @@ -435,7 +494,7 @@
   			<xsl:if test="count($insamepackage) &gt; 0">
   				<h2>Classes</h2>
   				<p>
  -				<table border="0" cellpadding="5" cellspacing="2" width="95%">
  +				<table class="details" border="0" cellpadding="5" cellspacing="2" width="95%">
   					<xsl:call-template name="testsuite.test.header"/>
   					<xsl:apply-templates select="$insamepackage" mode="print.test">
   						<xsl:sort select="@name"/>
  @@ -487,29 +546,29 @@
   
   <!-- class header -->
   <xsl:template name="testsuite.test.header">
  -	<tr bgcolor="#A6CAF0" valign="top">
  -		<td width="80%"><strong>Name</strong></td>
  -		<td><strong>Tests</strong></td>
  -		<td><strong>Errors</strong></td>
  -		<td><strong>Failures</strong></td>
  -		<td nowrap="nowrap"><strong>Time(s)</strong></td>
  +	<tr valign="top">
  +		<th width="80%">Name</th>
  +		<th>Tests</th>
  +		<th>Errors</th>
  +		<th>Failures</th>
  +		<th nowrap="nowrap">Time(s)</th>
   	</tr>
   </xsl:template>
   
   <!-- method header -->
   <xsl:template name="testcase.test.header">
  -	<tr bgcolor="#A6CAF0" valign="top">
  -		<td><strong>Name</strong></td>
  -		<td><strong>Status</strong></td>
  -		<td width="80%"><strong>Type</strong></td>
  -		<td nowrap="nowrap"><strong>Time(s)</strong></td>
  +	<tr valign="top">
  +		<th>Name</th>
  +		<th>Status</th>
  +		<th width="80%">Type</th>
  +		<th nowrap="nowrap">Time(s)</th>
   	</tr>
   </xsl:template>
   
   
   <!-- class information -->
   <xsl:template match="testsuite" mode="print.test">
  -	<tr bgcolor="#EEEEE" valign="top">		
  +	<tr valign="top">		
   		<xsl:attribute name="class">
   			<xsl:choose>
   				<xsl:when test="@errors[.&gt; 0]">Error</xsl:when>
  @@ -529,7 +588,7 @@
   </xsl:template>
   
   <xsl:template match="testcase" mode="print.test">
  -	<tr bgcolor="#EEEEE" valign="top">
  +	<tr valign="top">
   	    <xsl:attribute name="class">
   			<xsl:choose>
   				<xsl:when test="error">Error</xsl:when>
  @@ -589,6 +648,28 @@
   	<!-- the latter is better but might be problematic for non-21" monitors... -->
   	<!--pre><xsl:value-of select="."/></pre-->
   </xsl:template>
  +
  +<xsl:template name="JS-escape">
  +	<xsl:param name="string"/>
  +	<xsl:choose><!-- something isn't right here, basically all single quotes need to be replaced with backslash-single-quote
  +		<xsl:when test="contains($string,'&apos;')">
  +			<xsl:value-of select="substring-before($string,'&apos;')"/>
  +			\&apos;
  +			<xsl:call-template name="JS-escape">
  +				<xsl:with-param name="string" select="substring-after($string,'&apos;')"/>
  +			</xsl:call-template>
  +		</xsl:when> -->
  +		<xsl:when test="contains($string,'\')">
  +			<xsl:value-of select="substring-before($string,'\')"/>\\<xsl:call-template name="JS-escape">
  +				<xsl:with-param name="string" select="substring-after($string,'\')"/>
  +			</xsl:call-template>
  +		</xsl:when>
  +		<xsl:otherwise>
  +			<xsl:value-of select="$string"/>
  +		</xsl:otherwise>
  +	</xsl:choose>
  +</xsl:template>
  +
   
   <!--
   	template that will convert a carriage return into a br tag
  
  
  
  1.2       +135 -88   jakarta-ant/src/etc/junit-noframes.xsl
  
  Index: junit-noframes.xsl
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/etc/junit-noframes.xsl,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -w -u -r1.1 -r1.2
  --- junit-noframes.xsl	2001/08/07 22:03:27	1.1
  +++ junit-noframes.xsl	2001/08/30 13:26:36	1.2
  @@ -1,16 +1,4 @@
   <xsl:stylesheet	xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
  -
  -
  -<!-- ======================================================================
  -
  -	Stylesheet to transform an XML file generated by the Ant MAudit task into
  -	a set of JavaDoc-like HTML page to make pages more convenient to be browsed.
  -	
  -	It use the Xalan redirect extension to write to multiple output files.
  -	
  -	Note: HTML output can be made much more clean by removing non css attributes
  -
  -	====================================================================== -->
   <xsl:output method="html" indent="yes"/>
   <xsl:decimal-format decimal-separator="." grouping-separator="," />
   
  @@ -18,43 +6,43 @@
   	<HTML>
   		<HEAD>
   		<style type="text/css">
  -		BODY {
  +      body {
   			font:normal 68% verdana,arial,helvetica;
   			color:#000000;
   		}
  -		TABLE TR TD, TABLE TR TH {
  +      table tr td, table tr th {
   		    font-size: 68%;
   		}
  -		TABLE.details TR TH{
  +      table.details tr th{
   			font-weight: bold;
   			text-align:left;
  -			background:#A6CAF0;
  +      	background:#a6caf0;
   		}
  -		TABLE.details TR TD{
  -			background:#EEEEE0;
  +      table.details tr td{
  +      	background:#eeeee0;
   		}
   		
  -		P {
  +      p {
   			line-height:1.5em;
   			margin-top:0.5em; margin-bottom:1.0em;
   		}
  -		H1 {
  -			MARGIN: 0px 0px 5px; FONT: 165% verdana,arial,helvetica
  +      h1 {
  +      	margin: 0px 0px 5px; font: 165% verdana,arial,helvetica
   		}
  -		H2 {
  -			MARGIN-TOP: 1em; MARGIN-BOTTOM: 0.5em; FONT: bold 125% verdana,arial,helvetica
  +      h2 {
  +      	margin-top: 1em; margin-bottom: 0.5em; font: bold 125% verdana,arial,helvetica
   		}
  -		H3 {
  -			MARGIN-BOTTOM: 0.5em; FONT: bold 115% verdana,arial,helvetica
  +      h3 {
  +      	margin-bottom: 0.5em; font: bold 115% verdana,arial,helvetica
   		}
  -		H4 {
  -			MARGIN-BOTTOM: 0.5em; FONT: bold 100% verdana,arial,helvetica
  +      h4 {
  +      	margin-bottom: 0.5em; font: bold 100% verdana,arial,helvetica
   		}
  -		H5 {
  -			MARGIN-BOTTOM: 0.5em; FONT: bold 100% verdana,arial,helvetica
  +      h5 {
  +      	margin-bottom: 0.5em; font: bold 100% verdana,arial,helvetica
   		}
  -		H6 {
  -			MARGIN-BOTTOM: 0.5em; FONT: bold 100% verdana,arial,helvetica
  +      h6 {
  +      	margin-bottom: 0.5em; font: bold 100% verdana,arial,helvetica
   		}
   		.Error {
   			font-weight:bold; color:red;
  @@ -62,7 +50,46 @@
   		.Failure {
   			font-weight:bold; color:purple;
   		}
  +      .Properties {
  +      	text-align:right;
  +      }
   		</style>
  +      <script language="JavaScript">
  +        var TestCases = new Array();
  +        var cur;
  +        <xsl:for-each select="./testsuite">      
  +            <xsl:apply-templates select="properties"/>
  +        </xsl:for-each>
  +
  +       </script>
  +       <script language="JavaScript"><![CDATA[
  +        function displayProperties (name) {
  +          var win = window.open('','JUnitSystemProperties','scrollbars=1,resizable=1');
  +          var doc = win.document.open();
  +          doc.write("<html><head><title>Properties of " + name + "</title>");
  +          doc.write("<style>")
  +          doc.write("body {font:normal 68% verdana,arial,helvetica;	color:#000000; }");
  +          doc.write("table tr td, table tr th { font-size: 68%; }");
  +          doc.write("table.properties { border-collapse:collapse; border-left:solid 1 #cccccc; border-top:solid 1 #cccccc; padding:5px; }");
  +          doc.write("table.properties th { text-align:left; border-right:solid 1 #cccccc; border-bottom:solid 1 #cccccc; background-color:#eeeeee; }");
  +          doc.write("table.properties td { font:normal; text-align:left; border-right:solid 1 #cccccc; border-bottom:solid 1 #cccccc; background-color:#fffffff; }");
  +          doc.write("h3 { margin-bottom: 0.5em; font: bold 115% verdana,arial,helvetica }");
  +          doc.write("</style>");
  +          doc.write("</head><body>");
  +          doc.write("<h3>Properties of " + name + "</h3>");
  +          doc.write("<div align=\"right\"><a href=\"javascript:window.close();\">Close</a></div>");
  +          doc.write("<table class='properties'>");
  +          doc.write("<tr><th>Name</th><th>Value</th></tr>");
  +          for (prop in TestCases[name]) {
  +            doc.write("<tr><th>" + prop + "</th><td>" + TestCases[name][prop] + "</td></tr>");
  +          }
  +          doc.write("</table>");
  +          doc.write("</body></html>");
  +          doc.close();
  +          win.focus();
  +        }
  +      ]]>  
  +      </script>
   		</HEAD>
   		<body>
   			<a name="#top"></a>
  @@ -163,14 +190,25 @@
   			<h3>TestCase <xsl:value-of select="@name"/></h3>
   			
   			<table class="details" border="0" cellpadding="5" cellspacing="2" width="95%">
  -				<!-- Header -->
   				<xsl:call-template name="testcase.test.header"/>
  -
  -				<!-- match the testcases of this package -->
  -				<xsl:apply-templates select="testcase" mode="print.test"/>
  +			  <!--
  +			  test can even not be started at all (failure to load the class)
  +			  so report the error directly
  +			  -->
  +				<xsl:if test="./error">
  +					<tr class="Error">
  +						<td colspan="4"><xsl:apply-templates select="./error"/></td>
  +					</tr>
  +				</xsl:if>
  +				<xsl:apply-templates select="./testcase" mode="print.test"/>
   			</table>
  +            <div class="Properties">
  +                <a>
  +			        <xsl:attribute name="href">javascript:displayProperties('<xsl:value-of select="@package"/>.<xsl:value-of select="@name"/>');</xsl:attribute>
  +			        Properties &gt;&gt;
  +			    </a>
  +            </div>
   			<p/>
  -			<xsl:apply-templates select="properties"/>
   			
   			<a href="#top">Back to top</a>
   		</xsl:for-each>
  @@ -223,29 +261,18 @@
   		</table>
   	</xsl:template>
   	
  -	<xsl:template match="properties">
   	<!--
  -	    I have NO idea how to display properties ! :-(
  -	    It takes an incredible amount of space in the page and it's
  -	    really unreadable.
  -	    <xsl:variable name="count" select="count(property)"/>
  -	    <h3>System Properties</h3>
  -		<table class="details" border="0" cellpadding="5" cellspacing="2" width="95%">
  -		<tr valign="top">
  -			<th>Name</th>
  -			<th>Value</th>
  -		</tr>
  +   Write properties into a JavaScript data structure.
  +   This is based on the original idea by Erik Hatcher (erik@hatcher.net)
  +   -->
  +  <xsl:template match="properties">
  +    cur = TestCases['<xsl:value-of select="../@package"/>.<xsl:value-of select="../@name"/>'] = new Array();
   		<xsl:for-each select="property">
  -			<tr valign="top">
  -				<td><xsl:value-of select="@name"/></td>
  -				<td><xsl:value-of select="@value"/></td>
  -			</tr>
  +    <xsl:sort select="@name"/>
  +        cur['<xsl:value-of select="@name"/>'] = '<xsl:call-template name="JS-escape"><xsl:with-param name="string" select="@value"/></xsl:call-template>';
   		</xsl:for-each>
  -		</table>
  -	-->
   	</xsl:template>
   	
  -	
   <!-- Page HEADER -->
   <xsl:template name="pageHeader">
   	<h1>Unit Test Results</h1>
  @@ -345,8 +372,6 @@
   </xsl:template>
   
   
  -<!-- Note : the below template error and failure are the same style
  -			so just call the same style store in the toolkit template -->
   <xsl:template match="failure">
   	<xsl:call-template name="display-failures"/>
   </xsl:template>
  @@ -373,6 +398,28 @@
   	<!-- the later is better but might be problematic for non-21" monitors... -->
   	<!--pre><xsl:value-of select="."/></pre-->
   </xsl:template>
  +
  +<xsl:template name="JS-escape">
  +	<xsl:param name="string"/>
  +	<xsl:choose><!-- something isn't right here, basically all single quotes need to be replaced with backslash-single-quote
  +		<xsl:when test="contains($string,'&apos;')">
  +			<xsl:value-of select="substring-before($string,'&apos;')"/>
  +			\&apos;
  +			<xsl:call-template name="JS-escape">
  +				<xsl:with-param name="string" select="substring-after($string,'&apos;')"/>
  +			</xsl:call-template>
  +		</xsl:when> -->
  +		<xsl:when test="contains($string,'\')">
  +			<xsl:value-of select="substring-before($string,'\')"/>\\<xsl:call-template name="JS-escape">
  +				<xsl:with-param name="string" select="substring-after($string,'\')"/>
  +			</xsl:call-template>
  +		</xsl:when>
  +		<xsl:otherwise>
  +			<xsl:value-of select="$string"/>
  +		</xsl:otherwise>
  +	</xsl:choose>
  +</xsl:template>
  +
   
   <!--
   	template that will convert a carriage return into a br tag
  
  
  
  1.3       +2 -1      jakarta-ant/src/etc/testcases/taskdefs/optional/antlr/antlr.xml
  
  Index: antlr.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/etc/testcases/taskdefs/optional/antlr/antlr.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -w -u -r1.2 -r1.3
  --- antlr.xml	2001/02/04 13:59:03	1.2
  +++ antlr.xml	2001/08/30 13:26:36	1.3
  @@ -2,7 +2,7 @@
   
   <project name="antlr-test" basedir="." default="test1">
   
  -  <property name="tmp.dir" value="antlr.tmp"/>
  +  <property name="tmp.dir" location="antlr.tmp"/>
   
   
     <target name="test1">
  @@ -18,6 +18,7 @@
     </target>
   
     <target name="test3">
  +    <deltree dir="${tmp.dir}"/>
       <mkdir dir="${tmp.dir}"/>
       <antlr target="antlr.g" outputdirectory="${tmp.dir}"/>
     </target>
  
  
  
  1.3       +43 -37    jakarta-ant/src/etc/testcases/types/filterset.xml
  
  Index: filterset.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/etc/testcases/types/filterset.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -w -u -r1.2 -r1.3
  --- filterset.xml	2001/08/18 14:59:38	1.2
  +++ filterset.xml	2001/08/30 13:26:36	1.3
  @@ -34,4 +34,10 @@
       <fixcrlf eol="lf" srcdir="." includes="dest3.txt"/>
     </target>
     
  +  <target name="cleanup">
  +    <delete file="dest1.txt" quiet="true" />
  +    <delete file="dest2.txt" quiet="true" />
  +    <delete file="dest3.txt" quiet="true" />
  +  </target>
  +
   </project>
  
  
  
  1.2       +5 -0      jakarta-ant/src/etc/testcases/types/description1.xml
  
  
  
  
  1.2       +6 -0      jakarta-ant/src/etc/testcases/types/description2.xml
  
  
  
  
  1.2       +6 -0      jakarta-ant/src/etc/testcases/types/description3.xml
  
  
  
  
  1.2       +6 -0      jakarta-ant/src/etc/testcases/types/description4.xml
  
  
  
  
  1.34      +4 -0      jakarta-ant/src/main/org/apache/tools/ant/AntClassLoader.java
  
  Index: AntClassLoader.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/AntClassLoader.java,v
  retrieving revision 1.33
  retrieving revision 1.34
  diff -u -w -u -r1.33 -r1.34
  --- AntClassLoader.java	2001/08/06 09:58:36	1.33
  +++ AntClassLoader.java	2001/08/30 13:26:36	1.34
  @@ -866,6 +866,9 @@
                   if (t instanceof ClassFormatError) {
                       throw (ClassFormatError)t;
                   }
  +                else if (t instanceof NoClassDefFoundError) {
  +                    throw (NoClassDefFoundError)t;
  +                }
                   else {
                       throw new IOException(t.toString());
                   }
  @@ -914,6 +917,7 @@
                       }
                   }
                   catch (IOException ioe) {
  +                    // ioe.printStackTrace();
                       log("Exception reading component " + pathComponent , Project.MSG_VERBOSE);
                   }
               }
  
  
  
  1.18      +6 -1      jakarta-ant/src/main/org/apache/tools/ant/DefaultLogger.java
  
  Index: DefaultLogger.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/DefaultLogger.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -w -u -r1.17 -r1.18
  --- DefaultLogger.java	2001/08/07 12:24:23	1.17
  +++ DefaultLogger.java	2001/08/30 13:26:37	1.18
  @@ -143,7 +143,12 @@
                   error.printStackTrace(err);
               }
               else {
  +                if (error instanceof BuildException) {
  +                    err.println(error.toString());
  +                }
  +                else {
                   err.println(error.getMessage());
  +                }
               }
           }
   
  
  
  
  1.9       +1 -1      jakarta-ant/src/main/org/apache/tools/ant/XmlLogger.java
  
  Index: XmlLogger.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/XmlLogger.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -w -u -r1.8 -r1.9
  --- XmlLogger.java	2001/08/08 15:28:48	1.8
  +++ XmlLogger.java	2001/08/30 13:26:37	1.9
  @@ -248,7 +248,7 @@
           }
           messageElement.setAttribute(PRIORITY_ATTR, name);
   
  -        Text messageText = doc.createTextNode(event.getMessage());
  +        Text messageText = doc.createCDATASection(event.getMessage());
           messageElement.appendChild(messageText);
   
           TimedElement parentElement = null;
  
  
  
  1.15      +7 -0      jakarta-ant/src/main/org/apache/tools/ant/taskdefs/ExecuteOn.java
  
  Index: ExecuteOn.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/taskdefs/ExecuteOn.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -w -u -r1.14 -r1.15
  --- ExecuteOn.java	2001/07/12 12:06:42	1.14
  +++ ExecuteOn.java	2001/08/30 13:26:37	1.15
  @@ -330,7 +330,14 @@
               }
   
           } else { // no targetFilePos
  +
  +            // 0 --> srcIndex
               System.arraycopy(orig, 0, result, 0, srcIndex);
  +            // srcIndex --> end
  +            System.arraycopy(orig, srcIndex, result, 
  +                             srcIndex + srcFiles.length,
  +                             orig.length - srcIndex);
  +
           }
   
           // fill in source file names
  
  
  
  1.69      +584 -558  jakarta-ant/src/main/org/apache/tools/ant/taskdefs/Javac.java
  
  Index: Javac.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/taskdefs/Javac.java,v
  retrieving revision 1.68
  retrieving revision 1.69
  diff -u -w -u -r1.68 -r1.69
  --- Javac.java	2001/08/18 14:59:39	1.68
  +++ Javac.java	2001/08/30 13:26:37	1.69
  @@ -116,6 +116,8 @@
       private boolean includeJavaRuntime = false;
       private boolean fork = false;
       private boolean nowarn = false;
  +    private String memoryInitialSize;
  +    private String memoryMaximumSize;
   
       protected boolean failOnError = true;
       protected File[] compileList = new File[0];
  @@ -299,6 +301,30 @@
       }
   
       /**
  +     * Set the memoryInitialSize flag.
  +     */
  +    public void setMemoryInitialSize(String memoryInitialSize) {
  +        this.memoryInitialSize = memoryInitialSize;
  +    }
  +
  +    /** Gets the memoryInitialSize flag. */
  +    public String getMemoryInitialSize() {
  +        return memoryInitialSize;
  +    }
  +
  +    /**
  +     * Set the memoryMaximumSize flag.
  +     */
  +    public void setMemoryMaximumSize(String memoryMaximumSize) {
  +        this.memoryMaximumSize = memoryMaximumSize;
  +    }
  +
  +    /** Gets the memoryMaximumSize flag. */
  +    public String getMemoryMaximumSize() {
  +        return memoryMaximumSize;
  +    }
  +
  +    /**
        * Set the Java source file encoding name.
        */
       public void setEncoding(String encoding) {
  
  
  
  1.59      +1 -2      jakarta-ant/src/main/org/apache/tools/ant/taskdefs/Javadoc.java
  
  Index: Javadoc.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/taskdefs/Javadoc.java,v
  retrieving revision 1.58
  retrieving revision 1.59
  diff -u -w -u -r1.58 -r1.59
  --- Javadoc.java	2001/08/18 14:59:39	1.58
  +++ Javadoc.java	2001/08/30 13:26:37	1.59
  @@ -679,14 +679,13 @@
           }
   
           public String getPackages() {
  -            StringBuffer p = new StringBuffer( "\"" );
  +            StringBuffer p = new StringBuffer();
               for (int i = 0; i < packages.size(); i++) {
                   if ( i > 0 ) {
                       p.append( ":" );
                   }
                   p.append( packages.elementAt(i).toString() );
               }
  -            p.append( "\"" );
               return p.toString();
           }
       }
  
  
  
  1.5       +1 -5      jakarta-ant/src/main/org/apache/tools/ant/taskdefs/Manifest.java
  
  Index: Manifest.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/taskdefs/Manifest.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -w -u -r1.4 -r1.5
  --- Manifest.java	2001/08/01 12:56:23	1.4
  +++ Manifest.java	2001/08/30 13:26:37	1.5
  @@ -450,11 +450,6 @@
        */
       public Manifest(InputStream is) throws ManifestException, IOException {
           BufferedReader reader = new BufferedReader(new InputStreamReader(is));
  -        String line = reader.readLine();
  -        if (line == null) {
  -            return;
  -        }
  -        
           // This should be the manifest version
           String nextSectionName = mainSection.read(reader);
           String readManifestVersion = mainSection.getAttributeValue(ATTRIBUTE_MANIFEST_VERSION);
  @@ -463,6 +458,7 @@
               mainSection.removeAttribute(ATTRIBUTE_MANIFEST_VERSION);
           }
   
  +        String line = null;
           while ((line = reader.readLine()) != null) {
               if (line.length() == 0) {
                   continue;
  
  
  
  1.32      +12 -0     jakarta-ant/src/main/org/apache/tools/ant/taskdefs/Property.java
  
  Index: Property.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/taskdefs/Property.java,v
  retrieving revision 1.31
  retrieving revision 1.32
  diff -u -w -u -r1.31 -r1.32
  --- Property.java	2001/07/31 11:24:41	1.31
  +++ Property.java	2001/08/30 13:26:37	1.32
  @@ -160,6 +160,18 @@
       }
   
       public void execute() throws BuildException {
  +        if (name != null) {
  +            if (value == null && ref == null) {
  +                throw new BuildException("You must specify value, location or refid with the name attribute",
  +                                         location);
  +            }
  +        } else {
  +            if (file == null && resource == null && env == null) {
  +                throw new BuildException("You must specify file, resource or environment when not using the name attribute",
  +                                         location);
  +            }
  +        }
  +
           if ((name != null) && (value != null)) {
               addProperty(name, value);
           }
  
  
  
  1.25      +1 -1      jakarta-ant/src/main/org/apache/tools/ant/taskdefs/XSLTProcess.java
  
  Index: XSLTProcess.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/taskdefs/XSLTProcess.java,v
  retrieving revision 1.24
  retrieving revision 1.25
  diff -u -w -u -r1.24 -r1.25
  --- XSLTProcess.java	2001/08/18 14:59:39	1.24
  +++ XSLTProcess.java	2001/08/30 13:26:37	1.25
  @@ -88,7 +88,6 @@
    * @author <a href="mailto:rubys@us.ibm.com">Sam Ruby</a>
    * @author <a href="mailto:russgold@acm.org">Russell Gold</a>
    * @author <a href="stefan.bodewig@epost.de">Stefan Bodewig</a>
  - * @version $Revision: 1.24 $ $Date: 2001/08/18 14:59:39 $
    */
   public class XSLTProcess extends MatchingTask {
   
  @@ -268,6 +267,7 @@
                   loadClass("org.apache.tools.ant.taskdefs.optional.TraXLiaison");
               liaison = (XSLTLiaison)clazz.newInstance();
           } else if (proc.equals("xslp")) {
  +            log("DEPRECATED - xslp processor is deprecated. Use trax or xalan instead.");
               final Class clazz =
                   loadClass("org.apache.tools.ant.taskdefs.optional.XslpLiaison");
               liaison = (XSLTLiaison) clazz.newInstance();
  
  
  
  1.8       +433 -416  jakarta-ant/src/main/org/apache/tools/ant/taskdefs/compilers/DefaultCompilerAdapter.java
  
  Index: DefaultCompilerAdapter.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/taskdefs/compilers/DefaultCompilerAdapter.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -w -u -r1.7 -r1.8
  --- DefaultCompilerAdapter.java	2001/08/18 14:59:39	1.7
  +++ DefaultCompilerAdapter.java	2001/08/30 13:26:37	1.8
  @@ -92,6 +92,8 @@
       protected Location location;
       protected boolean includeAntRuntime;
       protected boolean includeJavaRuntime;
  +    protected String memoryInitialSize;
  +    protected String memoryMaximumSize;
   
       protected File[] compileList;
       protected static String lSep = System.getProperty("line.separator");
  @@ -116,6 +118,8 @@
           location = attributes.getLocation();
           includeAntRuntime = attributes.getIncludeantruntime();
           includeJavaRuntime = attributes.getIncludejavaruntime();
  +        memoryInitialSize = attributes.getMemoryInitialSize();
  +        memoryMaximumSize = attributes.getMemoryMaximumSize();
       }
   
       public Javac getJavac() {
  @@ -206,6 +210,19 @@
       protected Commandline setupJavacCommandlineSwitches(Commandline cmd) {
           Path classpath = getCompileClasspath();
   
  +        // we cannot be using Java 1.0 when forking, so we only have to
  +        // distinguish between Java 1.1, and Java 1.2 and higher, as Java 1.1
  +        // has its own parameter format
  +        boolean usingJava1_1 = Project.getJavaVersion().equals(Project.JAVA_1_1);
  +        String memoryParameterPrefix = usingJava1_1 ? "-J-" : "-J-X";
  +        if (memoryInitialSize != null) {
  +            cmd.createArgument().setValue(memoryParameterPrefix+"ms"+memoryInitialSize);
  +        }
  +
  +        if (memoryMaximumSize != null) {
  +            cmd.createArgument().setValue(memoryParameterPrefix+"mx"+memoryMaximumSize);
  +        }
  +
           if (attributes.getNowarn()) {
               cmd.createArgument().setValue("-nowarn");
           }
  
  
  
  1.9       +2 -2      jakarta-ant/src/main/org/apache/tools/ant/taskdefs/optional/ejb/BorlandDeploymentTool.java
  
  Index: BorlandDeploymentTool.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/taskdefs/optional/ejb/BorlandDeploymentTool.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -w -u -r1.8 -r1.9
  --- BorlandDeploymentTool.java	2001/08/08 11:52:25	1.8
  +++ BorlandDeploymentTool.java	2001/08/30 13:26:37	1.9
  @@ -215,10 +215,10 @@
        */
       protected void addVendorFiles(Hashtable ejbFiles, String ddPrefix) {
   
  -        File borlandDD = new File(getConfig().descriptorDir,BAS_DD);
  +        File borlandDD = new File(getConfig().descriptorDir,ddPrefix + BAS_DD);
           if (borlandDD.exists()) {
               log("Borland specific file found "+ borlandDD,  Project.MSG_VERBOSE);
  -            ejbFiles.put(META_DIR + BAS_DD, ddPrefix + borlandDD);
  +            ejbFiles.put(META_DIR + BAS_DD,  borlandDD);
           }
           else {
               log("Unable to locate borland deployment descriptor. It was expected to be in " + 
  
  
  
  1.12      +23 -23    jakarta-ant/src/main/org/apache/tools/ant/taskdefs/optional/ejb/WLRun.java
  
  Index: WLRun.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/taskdefs/optional/ejb/WLRun.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -w -u -r1.11 -r1.12
  --- WLRun.java	2001/08/18 14:59:40	1.11
  +++ WLRun.java	2001/08/30 13:26:37	1.12
  @@ -183,34 +183,34 @@
                                        " is not valid");
           }
   
  -        File securityPolicyFile = null;
  -        if (securityPolicy == null) {
  -            securityPolicyFile = new File(weblogicSystemHome, DEFAULT_WL60_POLICY_FILE);
  +        if (beaHome != null) {
  +            executeWLS6();
  +        } else {
  +            executeWLS();
           }
  -        else {
  -            securityPolicyFile = new File(weblogicSystemHome, securityPolicy);
           }
   
  -        if (!securityPolicyFile.exists()) {
  -            // OK it maybe an absolute path. Use the project to resolve it
  +    private File findSecurityPolicyFile(String defaultSecurityPolicy) {
  +        String securityPolicy = this.securityPolicy;
  +        if (securityPolicy == null) {
  +            securityPolicy = defaultSecurityPolicy;
  +        }
  +        File securityPolicyFile = new File( weblogicSystemHome, securityPolicy );
  +        // If an explicit securityPolicy file was specified, it maybe an
  +        // absolute path.  Use the project to resolve it.
  +        if (this.securityPolicy != null && !securityPolicyFile.exists()) {
               securityPolicyFile = project.resolveFile(securityPolicy);
  +        }
  +        // If we still can't find it, complain
               if (!securityPolicyFile.exists()) {
                   throw new BuildException("Security policy " + securityPolicy +
                                            " was not found.");
  -            }                                         
           }
  -
  -
  -        if (beaHome != null) {
  -            executeWLS6(securityPolicyFile);
  -        }
  -        else {
  -            executeWLS(securityPolicyFile);
  +        return securityPolicyFile;
           }
  -    }
  -    
  -    private void executeWLS6(File securityPolicyFile) {
           
  +    private void executeWLS6() {
  +        File securityPolicyFile = findSecurityPolicyFile( DEFAULT_WL60_POLICY_FILE );
           if (!beaHome.isDirectory()) {
               throw new BuildException("BEA home " + beaHome.getPath() + 
                                        " is not valid");
  @@ -258,9 +258,9 @@
               throw new BuildException("Execution of weblogic server failed");
           }
        }
  -    
  -    private void executeWLS(File securityPolicyFile) {
   
  +    private void executeWLS() {
  +        File securityPolicyFile = findSecurityPolicyFile( DEFAULT_WL51_POLICY_FILE );
           File propertiesFile = null;
           
   
  
  
  
  1.8       +3 -1      jakarta-ant/src/main/org/apache/tools/ant/taskdefs/optional/net/FTP.java
  
  Index: FTP.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/taskdefs/optional/net/FTP.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -w -u -r1.7 -r1.8
  --- FTP.java	2001/07/27 14:50:43	1.7
  +++ FTP.java	2001/08/30 13:26:37	1.8
  @@ -586,7 +586,9 @@
   
           FTPFile[] files = ftp.listFiles(remoteFile);
   
  -        if (files == null)
  +        // For Microsoft's Ftp-Service an Array with length 0 is 
  +        // returned if configured to return listings in "MS-DOS"-Format
  +        if (files == null || files.length == 0)
           {
               // If we are sending files, then assume out of date.
               // If we are getting files, then throw an error
  
  
  
  1.5       +2 -2      jakarta-ant/src/main/org/apache/tools/ant/taskdefs/rmic/WLRmic.java
  
  Index: WLRmic.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/taskdefs/rmic/WLRmic.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -w -u -r1.4 -r1.5
  --- WLRmic.java	2001/07/22 13:12:29	1.4
  +++ WLRmic.java	2001/08/30 13:26:37	1.5
  @@ -80,7 +80,7 @@
               Class c = Class.forName("weblogic.rmic");
               Method doRmic = c.getMethod("main", 
                                           new Class [] { String[].class });
  -            doRmic.invoke(null, new Object[] {  });
  +            doRmic.invoke(null, new Object[] {cmd.getArguments()  });
               return true;
           } catch (ClassNotFoundException ex) {
               throw new BuildException("Cannot use WebLogic rmic, as it is not available"+
  
  
  
  1.17      +3 -2      jakarta-ant/src/main/org/apache/tools/ant/types/CommandlineJava.java
  
  Index: CommandlineJava.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/types/CommandlineJava.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -w -u -r1.16 -r1.17
  --- CommandlineJava.java	2001/08/03 20:47:33	1.16
  +++ CommandlineJava.java	2001/08/30 13:26:38	1.17
  @@ -285,7 +285,8 @@
       public int size() {
           int size = getActualVMCommand().size() + javaCommand.size() + sysProperties.size();
           // classpath is "-classpath <classpath>" -> 2 args
  -        if (classpath != null && classpath.size() > 0) {
  +        Path fullClasspath = classpath != null ? classpath.concatSystemClasspath("ignore") : null;
  +        if (fullClasspath != null && fullClasspath.toString().trim().length() > 0) {
               size += 2;
           }
           // jar execution requires an additional -jar option
  
  
  
  1.2       +9 -10     jakarta-ant/src/main/org/apache/tools/ant/types/Description.java
  
  Index: Description.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/types/Description.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -w -u -r1.1 -r1.2
  --- Description.java	2001/08/08 20:18:34	1.1
  +++ Description.java	2001/08/30 13:26:38	1.2
  @@ -67,20 +67,19 @@
    * overwrite the first.
    *
    * @author <a href="mailto:cstrong@arielpartners.com">Craeg Strong</a>
  - * @version $Revision: 1.1 $ $Date: 2001/08/08 20:18:34 $
  + * @version $Revision: 1.2 $ $Date: 2001/08/30 13:26:38 $
    */
   public class Description extends DataType {
      
  -   private Project project;
  -   
  -   public Description(Project project) {
  -      this.project = project;
  -   }
  -
       /**
        * Adds descriptive text to the project.
        */
      public void addText(String text) {
  +        String currentDescription = project.getDescription();
  +        if (currentDescription == null) {
         project.setDescription(text);
  +        } else {
  +            project.setDescription(currentDescription + text);
  +        }
      }
   }
  
  
  
  1.7       +11 -0     jakarta-ant/src/testcases/org/apache/tools/ant/taskdefs/TaskdefsTest.java
  
  Index: TaskdefsTest.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/testcases/org/apache/tools/ant/taskdefs/TaskdefsTest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -w -u -r1.6 -r1.7
  --- TaskdefsTest.java	2001/07/25 14:40:54	1.6
  +++ TaskdefsTest.java	2001/08/30 13:26:38	1.7
  @@ -66,6 +66,7 @@
       protected Project project;
       
       private StringBuffer logBuffer;
  +    private StringBuffer fullLogBuffer;
       private StringBuffer outBuffer;
       private StringBuffer errBuffer;
       private BuildException buildException;
  @@ -78,6 +79,12 @@
           return logBuffer.toString();
       }
   
  +    protected String getFullLog() { 
  +        return fullLogBuffer.toString();
  +    }
  +
  +    
  +
       protected void expectBuildException(String taskname, String cause) { 
           expectSpecificBuildException(taskname, cause, null);
       }
  @@ -136,6 +143,7 @@
       
       protected void configureProject(String filename) { 
           logBuffer = new StringBuffer();
  +        fullLogBuffer = new StringBuffer();
           project = new Project();
           project.init();
           project.setUserProperty( "ant.file" , new File(filename).getAbsolutePath() );
  @@ -156,6 +164,7 @@
               PrintStream err = new PrintStream(new AntOutputStream());
               System.setErr(err);
               logBuffer = new StringBuffer();
  +            fullLogBuffer = new StringBuffer();
               buildException = null;
               project.executeTarget(targetName);
           } finally { 
  @@ -253,6 +262,8 @@
               {
                   logBuffer.append(event.getMessage());
               }
  +            fullLogBuffer.append(event.getMessage());
  +            
           }
       }
   
  
  
  
  1.3       +6 -1      jakarta-ant/src/testcases/org/apache/tools/ant/taskdefs/optional/AbstractXSLTLiaisonTest.java
  
  Index: AbstractXSLTLiaisonTest.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/testcases/org/apache/tools/ant/taskdefs/optional/AbstractXSLTLiaisonTest.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -w -u -r1.2 -r1.3
  --- AbstractXSLTLiaisonTest.java	2001/08/18 14:59:40	1.2
  +++ AbstractXSLTLiaisonTest.java	2001/08/30 13:26:38	1.3
  @@ -62,6 +62,7 @@
   import javax.xml.parsers.DocumentBuilder;
   import javax.xml.parsers.DocumentBuilderFactory;
   import java.io.File;
  +import java.io.FileNotFoundException;
   import java.net.URL;
   
   /**
  @@ -85,8 +86,12 @@
       // to override
       protected abstract XSLTLiaison createLiaison() throws Exception ;
   
  -    protected File getFile(String name){
  +    /** load the file from the caller classloader that loaded this class */
  +    protected File getFile(String name) throws FileNotFoundException {
           URL url = getClass().getResource(name);
  +        if (url == null){
  +          throw new FileNotFoundException("Unable to load '" + name + "' from classpath");
  +        }
           return new File(url.getFile());
       }
   
  
  
  
  1.3       +4 -2      jakarta-ant/src/testcases/org/apache/tools/ant/types/FilterSetTest.java
  
  Index: FilterSetTest.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/testcases/org/apache/tools/ant/types/FilterSetTest.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -w -u -r1.2 -r1.3
  --- FilterSetTest.java	2001/08/18 14:59:40	1.2
  +++ FilterSetTest.java	2001/08/30 13:26:38	1.3
  @@ -72,14 +72,16 @@
   
       static private final int BUF_SIZE = 32768;
       
  -    private Project project;
  -
       public FilterSetTest(String name) {
           super(name);
       }
   
       public void setUp() { 
           configureProject("src/etc/testcases/types/filterset.xml");
  +    }
  +
  +    public void tearDown() {
  +        executeTarget("cleanup");
       }
   
       public void test1() { 
  
  
  
  1.2       +102 -0    jakarta-ant/src/testcases/org/apache/tools/ant/types/DescriptionTest.java
  
  
  
  

Mime
View raw message