brekke      02/03/17 19:54:03

  Modified:    .        build-test.xml
               src/rttest/org/apache/turbine
                        ConditionalValveServletTest.java
  Log:
  Need to explicitly exclude the JGenTest test screen module since the naming
  format conflicts with the naming format for the unit test cases.
  
  Removed unused sys properties and added the basedir property.  This provides
  the unit tests access to the base project dir and therefor the tests are not
  dependent on where they are started from.  Updated ConditionalValveServletTest
  to use this property to build the correct path to a directory it needed.
  
  Revision  Changes    Path
  1.15      +2 -4      jakarta-turbine-3/build-test.xml
  
  Index: build-test.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-turbine-3/build-test.xml,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -r1.14 -r1.15
  --- build-test.xml    11 Mar 2002 12:51:46 -0000      1.14
  +++ build-test.xml    18 Mar 2002 03:54:02 -0000      1.15
  @@ -94,6 +94,7 @@
           <fileset dir="${build.dest}">
             <include name="**/*Test.class"/>
             <exclude name="**/*ServletTest.class"/>
  +          <exclude name="org/mycompany/newapp/modules/screens/JGenTest.class"/>
           </fileset>
         </batchtest>
       </junit>
  @@ -144,10 +145,7 @@
           <path refid="classpath"/>
         </classpath>
   
  -      <sysproperty key="java.compiler" value="NONE" />
  -      <sysproperty key="java.net.namelookup.cache" value="0" />
  -      <sysproperty key="sun.net.inetaddr.ttl" value="0" />
  -      <sysproperty key="test.port" value="${test.port}" />
  +      <sysproperty key="basedir" value="${basedir}"/>
   
         <formatter type="plain" usefile="false"/>
         <batchtest>
  
  
  
  1.2       +7 -3      
jakarta-turbine-3/src/rttest/org/apache/turbine/ConditionalValveServletTest.java
  
  Index: ConditionalValveServletTest.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-turbine-3/src/rttest/org/apache/turbine/ConditionalValveServletTest.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ConditionalValveServletTest.java  11 Feb 2002 23:58:05 -0000      1.1
  +++ ConditionalValveServletTest.java  18 Mar 2002 03:54:02 -0000      1.2
  @@ -82,7 +82,7 @@
    * @author <a href="mailto:[EMAIL PROTECTED]";>Jeff Brekke</a>
    * @author <a href="mailto:[EMAIL PROTECTED]";>Jason van Zyl</a>
    * @author <a href="mailto:[EMAIL PROTECTED]";>James Taylor</a>
  - * @version $Id: ConditionalValveServletTest.java,v 1.1 2002/02/11 23:58:05 jtaylor 
Exp $
  + * @version $Id: ConditionalValveServletTest.java,v 1.2 2002/03/18 03:54:02 brekke 
Exp $
    */
   public class ConditionalValveServletTest
       extends ServletTestCase
  @@ -277,8 +277,12 @@
           // FIXME: Eventually we should be able to use some limited pieces of 
           // jgen (like parsing a file) without needing configuration, but until
           // then is there a better way to get this path? Using a filter perhaps?
  -        
  -        Util.init( "target/rttest/tomcat40/webapps/test/WEB-INF/conf/" );
  +
  +        String baseDir = System.getProperty("basedir");
  +        assertNotNull("Could not get the 'basedir' system property.", baseDir);
  +        String fs = System.getProperty("file.separator");
  +        assertNotNull("Could not get the 'file.separator' system property.", fs);
  +        Util.init( baseDir+fs+"target/rttest/tomcat40/webapps/test/WEB-INF/conf/" );
           
           // If it parses it must be a flash file
           
  
  
  

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to