You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@jspwiki.apache.org by aj...@apache.org on 2009/10/25 04:52:20 UTC

svn commit: r829488 - in /incubator/jspwiki/trunk: ./ .externalToolBuilders/ etc/ src/WebContent/WEB-INF/classes/ src/java/org/apache/wiki/ tests/etc/ tests/etc/WEB-INF/ tests/java/org/apache/wiki/ tests/java/org/apache/wiki/auth/ tests/java/org/apache...

Author: ajaquith
Date: Sun Oct 25 03:52:19 2009
New Revision: 829488

URL: http://svn.apache.org/viewvc?rev=829488&view=rev
Log:
Restructured "tests" Ant target so that all test fixtures used during the tests itself are now in build/tests. The original files used to construct the fixtures stay in tests/etc, but nothing in tests/etc are used when running the tests. The build/tests dir contains classes, classpath (copied from tests/etc), db (copied from etc/db), priha (the test page repository), reports (for JUnit test results) and workdir. The logfile for tests is now build/tests/jspwiki.log. In addition to these changes, the Ant tasks "init" and "tests-init" are now hooked into the Eclipse "clean" and "build project" commands as external builders. These ensure that the same test fixtures are set up if run from Eclipse.

Added:
    incubator/jspwiki/trunk/.externalToolBuilders/tests-init.launch
    incubator/jspwiki/trunk/tests/etc/CommentedPropertiesTest.properties
    incubator/jspwiki/trunk/tests/etc/groupdatabase.xml
    incubator/jspwiki/trunk/tests/etc/jspwiki.properties
    incubator/jspwiki/trunk/tests/etc/keychain   (with props)
    incubator/jspwiki/trunk/tests/etc/urlpattern.properties
    incubator/jspwiki/trunk/tests/etc/userdatabase.xml
Removed:
    incubator/jspwiki/trunk/src/WebContent/WEB-INF/classes/log4j.properties
    incubator/jspwiki/trunk/src/WebContent/WEB-INF/classes/priha.properties
    incubator/jspwiki/trunk/tests/etc/WEB-INF/keychain
    incubator/jspwiki/trunk/tests/etc/WEB-INF/urlpattern.properties
    incubator/jspwiki/trunk/tests/etc/groupdatabase.xml.tmpl
    incubator/jspwiki/trunk/tests/etc/test.properties
    incubator/jspwiki/trunk/tests/etc/userdatabase.xml.tmpl
Modified:
    incubator/jspwiki/trunk/.classpath
    incubator/jspwiki/trunk/.project
    incubator/jspwiki/trunk/ChangeLog
    incubator/jspwiki/trunk/build.properties
    incubator/jspwiki/trunk/build.xml
    incubator/jspwiki/trunk/etc/jspwiki.properties.tmpl
    incubator/jspwiki/trunk/src/java/org/apache/wiki/Release.java
    incubator/jspwiki/trunk/tests/etc/log4j.properties
    incubator/jspwiki/trunk/tests/etc/priha.properties
    incubator/jspwiki/trunk/tests/java/org/apache/wiki/TestEngine.java
    incubator/jspwiki/trunk/tests/java/org/apache/wiki/WikiEngineTest.java
    incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/UserManagerTest.java
    incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/authorize/LdapAuthorizerTest.java
    incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/login/AnonymousLoginModuleTest.java
    incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/login/CookieAssertionLoginModuleTest.java
    incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/login/UserDatabaseLoginModuleTest.java
    incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/login/WebContainerLoginModuleTest.java
    incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/user/XMLUserDatabaseTest.java
    incubator/jspwiki/trunk/tests/java/org/apache/wiki/parser/JSPWikiMarkupParserTest.java
    incubator/jspwiki/trunk/tests/java/org/apache/wiki/util/CommentedPropertiesTest.java

Modified: incubator/jspwiki/trunk/.classpath
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/.classpath?rev=829488&r1=829487&r2=829488&view=diff
==============================================================================
--- incubator/jspwiki/trunk/.classpath (original)
+++ incubator/jspwiki/trunk/.classpath Sun Oct 25 03:52:19 2009
@@ -9,7 +9,7 @@
 	<classpathentry kind="lib" path="tests/lib/jetty-plus-5.1.14.jar"/>
 	<classpathentry kind="lib" path="tests/lib/jetty-jmx-5.1.14.jar"/>
 	<classpathentry kind="lib" path="tests/lib/selenium-server-1.0b2.jar"/>
-	<classpathentry kind="lib" path="tests/etc"/>
+	<classpathentry kind="lib" path="build/tests/classpath"/>
 	<classpathentry kind="lib" path="tests/lib/hsqldb.jar"/>
 	<classpathentry kind="con" path="org.eclipse.jdt.junit.JUNIT_CONTAINER/3"/>
 	<classpathentry kind="output" path="build/classes"/>

Added: incubator/jspwiki/trunk/.externalToolBuilders/tests-init.launch
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/.externalToolBuilders/tests-init.launch?rev=829488&view=auto
==============================================================================
--- incubator/jspwiki/trunk/.externalToolBuilders/tests-init.launch (added)
+++ incubator/jspwiki/trunk/.externalToolBuilders/tests-init.launch Sun Oct 25 03:52:19 2009
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<launchConfiguration type="org.eclipse.ant.AntBuilderLaunchConfigurationType">
+<stringAttribute key="org.eclipse.ant.ui.ATTR_ANT_AFTER_CLEAN_TARGETS" value="init,tests-init,"/>
+<stringAttribute key="org.eclipse.ant.ui.ATTR_ANT_CLEAN_TARGETS" value="clean,"/>
+<stringAttribute key="org.eclipse.ant.ui.ATTR_ANT_MANUAL_TARGETS" value="init,tests-init,"/>
+<booleanAttribute key="org.eclipse.ant.ui.ATTR_TARGETS_UPDATED" value="true"/>
+<booleanAttribute key="org.eclipse.ant.ui.DEFAULT_VM_INSTALL" value="false"/>
+<stringAttribute key="org.eclipse.debug.core.ATTR_REFRESH_SCOPE" value="${container}"/>
+<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_PATHS">
+<listEntry value="/JSPWiki/build.xml"/>
+</listAttribute>
+<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_TYPES">
+<listEntry value="1"/>
+</listAttribute>
+<booleanAttribute key="org.eclipse.debug.ui.ATTR_LAUNCH_IN_BACKGROUND" value="false"/>
+<stringAttribute key="org.eclipse.jdt.launching.CLASSPATH_PROVIDER" value="org.eclipse.ant.ui.AntClasspathProvider"/>
+<booleanAttribute key="org.eclipse.jdt.launching.DEFAULT_CLASSPATH" value="true"/>
+<stringAttribute key="org.eclipse.jdt.launching.PROJECT_ATTR" value="JSPWiki"/>
+<stringAttribute key="org.eclipse.ui.externaltools.ATTR_LOCATION" value="${workspace_loc:/JSPWiki/build.xml}"/>
+<stringAttribute key="org.eclipse.ui.externaltools.ATTR_RUN_BUILD_KINDS" value="full,incremental,clean"/>
+<booleanAttribute key="org.eclipse.ui.externaltools.ATTR_TRIGGERS_CONFIGURED" value="true"/>
+</launchConfiguration>

Modified: incubator/jspwiki/trunk/.project
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/.project?rev=829488&r1=829487&r2=829488&view=diff
==============================================================================
--- incubator/jspwiki/trunk/.project (original)
+++ incubator/jspwiki/trunk/.project Sun Oct 25 03:52:19 2009
@@ -16,6 +16,16 @@
 			</arguments>
 		</buildCommand>
 		<buildCommand>
+			<name>org.eclipse.ui.externaltools.ExternalToolBuilder</name>
+			<triggers>clean,full,incremental,</triggers>
+			<arguments>
+				<dictionary>
+					<key>LaunchConfigHandle</key>
+					<value>&lt;project&gt;/.externalToolBuilders/tests-init.launch</value>
+				</dictionary>
+			</arguments>
+		</buildCommand>
+		<buildCommand>
 			<name>org.eclipse.jdt.core.javabuilder</name>
 			<arguments>
 			</arguments>

Modified: incubator/jspwiki/trunk/ChangeLog
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/ChangeLog?rev=829488&r1=829487&r2=829488&view=diff
==============================================================================
--- incubator/jspwiki/trunk/ChangeLog (original)
+++ incubator/jspwiki/trunk/ChangeLog Sun Oct 25 03:52:19 2009
@@ -1,3 +1,20 @@
+2009-10-24 Andrew Jaquith <ajaquith AT apache DOT org>
+
+        * 3.0.0-svn-170
+        
+        * Restructured "tests" Ant target so that all test fixtures used
+        during the tests itself are now in build/tests. The original files
+        used to construct the fixtures stay in tests/etc, but nothing in
+        tests/etc are used when running the tests. The build/tests dir
+        contains classes, classpath (copied from tests/etc), db (copied
+        from etc/db), priha (the test page repository), reports (for
+        JUnit test results) and workdir. The logfile for tests is now
+        build/tests/jspwiki.log. In addition to these changes,
+        the Ant tasks "init" and "tests-init" are now hooked into the
+        Eclipse "clean" and "build project" commands as external builders.
+        These ensure that the same test fixtures are set up if run from
+        Eclipse.
+        
 2009-10-17 Andrew Jaquith <ajaquith AT apache DOT org>
 
         * 3.0.0-svn-169

Modified: incubator/jspwiki/trunk/build.properties
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/build.properties?rev=829488&r1=829487&r2=829488&view=diff
==============================================================================
--- incubator/jspwiki/trunk/build.properties (original)
+++ incubator/jspwiki/trunk/build.properties Sun Oct 25 03:52:19 2009
@@ -30,13 +30,6 @@
 #
 @appname@=JSPWiki
 
-@tests.pagedir@=/tmp/testrepository
-@tests.workdir@=/tmp/testworkdir
-@tests.logfile@=/tmp/jspwikitests.log
-
-@tests.auth.filename=/tmp/testrepository/auth.txt
-@tests.filter@=tests/etc/filters.xml
-
 # JavaMail configuration
 @mail.smtp.host@=127.0.0.1
 @mail.smtp.port@=25
@@ -46,7 +39,7 @@
 
 #  Set this property to 'true' if you want to build WARs
 #  that contain pre-compiled JSPs (which load faster).
-compile.jsps = true
+#compile.jsps = true
 
 #  Enable these if you wish to create a static content tarball
 #  for use with Apache or another front-end web server.

Modified: incubator/jspwiki/trunk/build.xml
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/build.xml?rev=829488&r1=829487&r2=829488&view=diff
==============================================================================
--- incubator/jspwiki/trunk/build.xml (original)
+++ incubator/jspwiki/trunk/build.xml Sun Oct 25 03:52:19 2009
@@ -100,7 +100,12 @@
   <property name="tests" value="tests" />
   <property name="tests.src" value="${tests}/java" />
   <property name="tests.build" value="${build}/tests/classes" />
+  <property name="tests.classpath" value="${build}/tests/classpath" />
+  <property name="tests.webinf" value="${tests.classpath}/WEB-INF" />
+  <property name="tests.db" value="${build}/tests/db" />
+  <property name="tests.pagedir" value="${build}/tests/priha" />
   <property name="tests.reports" value="${build}/tests/reports" />
+  <property name="tests.workdir" value="${build}/tests/workdir" />
   
   <!-- The location of the JAR file for the test classes -->
   <property name="testjarfile" location="${build}/${ant.project.name}-tests.jar" />
@@ -154,9 +159,9 @@
      </fileset>
   </path>
 
-  <!-- The path used for running tests.  We add the tests/etc directory
+  <!-- The path used for running tests.  We add the tests.classpath directory
        to the base path defined above, since we put all the relevant
-       .properties-files in tests/etc. -->
+       .properties-files there. -->
   <path id="path.tests">
      <pathelement location="${jarfile}" />
      <pathelement location="${testjarfile}" />
@@ -168,7 +173,7 @@
         <include name="*.jar" />
      </fileset>
      <pathelement path="${code.i18n}"/>
-     <pathelement path="${tests}/etc" />
+     <pathelement path="${tests.classpath}" />
   </path>
 
   <!-- The prefix to use when reading environment variables -->
@@ -183,19 +188,13 @@
           description="Initializes everything, creates directories, etc."
           depends="mkpropertyfile">
      <mkdir dir="${code.build}" />
-     <mkdir dir="${tests.build}" />
-     <mkdir dir="${tests.reports}" />
-     <mkdir dir="${@tests.pagedir@}" />
   </target>
 
   <target name="mkpropertyfile"
           description="Builds the correct propertyfile from the build.properties">
      <copy file="etc/jspwiki.properties.tmpl" tofile="${code.web}/WEB-INF/jspwiki.properties" />
-     <copy file="${tests}/etc/jspwiki.properties.tmpl" tofile="${tests}/etc/jspwiki.properties" />
      <replace file="${code.web}/WEB-INF/jspwiki.properties"
               replacefilterfile="${build.properties}" />
-     <replace file="${tests}/etc/jspwiki.properties"
-              replacefilterfile="${build.properties}" />
   </target>
 
   <!-- Removes the build directory and the tests build directory -->
@@ -204,7 +203,6 @@
     <delete dir="${build}" />
     <delete dir="${tests.build}" />
     <delete file="${code.web}/WEB-INF/jspwiki.properties" />
-    <delete file="${tests}/etc/jspwiki.properties" />
     <delete>
       <fileset dir="." includes="**/*~" defaultexcludes="no"/>
       <fileset dir="." includes="**/#*#" defaultexcludes="no"/>
@@ -674,40 +672,60 @@
   <!-- Running tests -->
 
   <target name="tests-init" depends="mkpropertyfile">
-      <!-- Build up the /etc directory for testing -->
-      <delete file="${tests}/etc/userdatabase.xml" />
-      <delete file="${tests}/etc/userdatabase.xml.old" />
-      <copy file="${tests}/etc/userdatabase.xml.tmpl" toFile="${tests}/etc/userdatabase.xml"/>
-      <delete file="${tests}/etc/groupdatabase.xml" />
-      <delete file="${tests}/etc/groupdatabase.xml.old" />
-      <copy file="${tests}/etc/groupdatabase.xml.tmpl" toFile="${tests}/etc/groupdatabase.xml"/>
-      <mkdir dir="${tests}/etc/WEB-INF" />
-
-      <!-- Create web.xml files for testing -->
-      <copy file="${code.web}/WEB-INF/web.xml" tofile="${webtests.build}/web.xml.custom" overwrite="true" />
-
-      <!-- For web unit tests, turn off SSL (self-signed certs b0rk
-           the tests) and enable JDBC refs -->
-      <replace file="${webtests.build}/web.xml.custom"
-               token="CONFIDENTIAL" value="NONE" />
-      <replace file="${webtests.build}/web.xml.custom"
-               token="&lt;!--  REMOVE ME TO ENABLE JDBC DATABASE" value="" />
-      <replace file="${webtests.build}/web.xml.custom"
-               token="REMOVE ME TO ENABLE JDBC DATABASE  --&gt;" value="" />
-
-      <!-- For unit testing, turn on container auth -->
-      <copy file="${webtests.build}/web.xml.custom"
-          tofile="${webtests.build}/web.xml.container" overwrite="true" />
-      <replace file="${webtests.build}/web.xml.container"
-               token="&lt;!--  REMOVE ME TO ENABLE CONTAINER-MANAGED AUTH" value="" />
-      <replace file="${webtests.build}/web.xml.container"
-               token="REMOVE ME TO ENABLE CONTAINER-MANAGED AUTH  --&gt;" value="" />
-      <copy file="${webtests.build}/web.xml.container"
-          tofile="${tests}/etc/WEB-INF/web.xml" overwrite="true" />
-
-      <!-- Copy jspwiki.properties to the test WEB-INF -->
-      <copy file="${code.web}/WEB-INF/jspwiki.properties"
-          tofile="${tests}/etc/WEB-INF/jspwiki.properties" overwrite="true" />
+
+    <!-- Create test files for classpath -->
+    <copy toDir="${tests.classpath}" overwrite="true">
+      <fileset dir="${tests}/etc">
+        <include name="CommentedPropertiesTest.properties" />
+        <include name="log4j.properties" />
+        <include name="priha.properties" />
+      </fileset>
+    </copy>
+        
+    <!-- Create test WEB-INF -->
+    <copy toDir="${tests.webinf}" overwrite="true">
+      <fileset dir="${tests}/etc">
+        <include name="filters.xml" />
+        <include name="groupdatabase.xml" />
+        <include name="jspwiki_vers.properties" />
+        <include name="jspwiki_rcs.properties" />
+        <include name="jspwiki.policy" />
+        <include name="jspwiki.properties" />
+        <include name="jspwiki-testUserPolicy.policy" />
+        <include name="keychain" />
+        <include name="urlpattern.properties" />
+        <include name="userdatabase.xml" />
+      </fileset>
+    </copy>
+    
+    <!-- Create web.xml files for testing -->
+    <copy file="${code.web}/WEB-INF/web.xml" tofile="${webtests.build}/web.xml.custom" overwrite="true" />
+
+    <!-- For web unit tests, turn off SSL (self-signed certs b0rk
+          the tests) and enable JDBC refs -->
+    <replace file="${webtests.build}/web.xml.custom"
+              token="CONFIDENTIAL" value="NONE" />
+    <replace file="${webtests.build}/web.xml.custom"
+              token="&lt;!--  REMOVE ME TO ENABLE JDBC DATABASE" value="" />
+    <replace file="${webtests.build}/web.xml.custom"
+              token="REMOVE ME TO ENABLE JDBC DATABASE  --&gt;" value="" />
+
+    <!-- For unit testing, turn on container auth -->
+    <copy file="${webtests.build}/web.xml.custom"
+        tofile="${webtests.build}/web.xml.container" overwrite="true" />
+    <replace file="${webtests.build}/web.xml.container"
+              token="&lt;!--  REMOVE ME TO ENABLE CONTAINER-MANAGED AUTH" value="" />
+    <replace file="${webtests.build}/web.xml.container"
+              token="REMOVE ME TO ENABLE CONTAINER-MANAGED AUTH  --&gt;" value="" />
+              
+    <mkdir dir="${tests.build}" />
+    <mkdir dir="${tests.classpath}/WEB-INF" />
+    <mkdir dir="${tests.reports}" />
+    <mkdir dir="${tests.pagedir}" />
+    <mkdir dir="${tests.workdir}" />
+    <copy file="${webtests.build}/web.xml.container"
+        tofile="${tests.classpath}/WEB-INF/web.xml" overwrite="true" />
+        
   </target>
 
   <!-- This target runs the JUnit tests that are available
@@ -814,7 +832,7 @@
     <mkdir dir="${webtests.build}" />
   
     <!-- Create the master jspwiki.properties template for all webtests -->
-    <copy file="${tests}/etc/jspwiki.properties"
+    <copy file="${tests.classpath}/jspwiki.properties"
         toFile="${webtests.build}/jspwiki.properties.tmpl" flatten="true" />
     <propertyfile file="${webtests.build}/jspwiki.properties.tmpl">
       <entry key="jspwiki.authorizer" value="org.apache.wiki.auth.authorize.WebContainerAuthorizer" />
@@ -921,7 +939,7 @@
         <fileset dir="etc">
           <include name="jspwiki.policy" />
         </fileset>
-        <fileset dir="${tests}/etc" includes="userdatabase.xml groupdatabase.xml" />
+        <fileset dir="${tests.classpath}" includes="userdatabase.xml groupdatabase.xml" />
       </copy>
       <copy toFile="@{context.dir}/webapp/WEB-INF/web.xml" file="@{webxml}" flatten="true" />
       
@@ -945,7 +963,7 @@
         <fileset dir="etc" includes="oscache.properties" />
       </copy>
       <copy toDir="@{context.dir}/webapp/WEB-INF/classes">
-        <fileset dir="${tests}/etc" includes="log4j.properties" />
+        <fileset dir="${tests.classpath}" includes="log4j.properties" />
         <filterset>
           <filter token="logfile" value="@{context.dir}/jetty.log" />
         </filterset>
@@ -1089,7 +1107,7 @@
        The complete list of customizable table properties are found
        in etc/jspwiki.properties.tmpl. If you don't customize them,
        JSPWiki will use some sensible defaults. For unit testing purposes,
-       this script will always use the defaults from 'tests/etc/jspwiki.properties',
+       this script will always use the defaults from '${tests.classpath}/jspwiki.properties',
        then apply any custom properties defined in your build.properties file.
 
        All of this may sound complicated, but it really isn't. If you use Hypersonic,
@@ -1159,7 +1177,8 @@
     <check-file file="${jdbc.driver.jar}"            prop="jdbc.jar.present" />
 
     <!-- Bulk-copy the table setup/teardown scripts -->
-    <property name="tests.db.scripts" value="${tests}/etc/db/${jdbc.driver.id}" />
+    <mkdir dir="${tests.db}" />
+    <property name="tests.db.scripts" value="${tests.db}/${jdbc.driver.id}" />
     <mkdir dir="${tests.db.scripts}" />
     <copy toDir="${tests.db.scripts}" overwrite="true">
       <fileset dir="${db.scripts}" />
@@ -1182,7 +1201,7 @@
     <property name="db.props.exist" value="true" />
 
     <!-- Dump all of the JDBC properties where our test scripts can find them -->
-    <echoproperties prefix="jdbc." destfile="${tests}/etc/db/jdbc.properties" />
+    <echoproperties prefix="jdbc." destfile="${tests.db}/jdbc.properties" />
   </target>
 
   <target name="db-setup" depends="db-properties,hsql-init" if="db.props.exist">
@@ -1231,8 +1250,8 @@
 
   <target name="hsql-check-start" depends="db-properties">
     <echo message="Checking to see if Hypersonic JDBC server is running already." />
-    <property file="${tests}/etc/db/hsql/server.properties" prefix="hsql" />
-    <fail unless="hsql.server.port">Failed to load Hypersonic JDBC properties from ${tests.src}/etc/db/hsql/server.properties</fail>
+    <property file="${tests.db}/hsql/server.properties" prefix="hsql" />
+    <fail unless="hsql.server.port">Failed to load Hypersonic JDBC properties from ${tests.db}/hsql/server.properties</fail>
     <condition property="hsql.up">
       <socket server="localhost" port="${hsql.server.port}" />
     </condition>
@@ -1241,17 +1260,17 @@
   <target name="hsql-start" depends="hsql-check-start" unless="hsql.up"
     description="Starts the Hypersonic database for testing.">
     <echo message="Starting up Hypersonic JDBC server on localhost." />
-    <delete file="${tests}/etc/db/hsql/jspwiki.lck"/>
+    <delete file="${tests.db}/hsql/jspwiki.lck"/>
     <java fork="yes" spawn="yes" classname="org.hsqldb.Server"
-      dir="${tests}/etc/db/hsql">
+      dir="${tests.db}/hsql">
       <classpath>
         <pathelement location="${jdbc.driver.jar}" />
       </classpath>
     </java>
     <sleep seconds="5" />
-    <available file="${tests}/etc/db/hsql/jspwiki.lck" property="hsql.up"/>
+    <available file="${tests.db}/hsql/jspwiki.lck" property="hsql.up"/>
     <fail unless="hsql.up">Hypersonic didn't appear to start up properly. You can start it manually from the command line as follows:
-   cd tests/etc/db/hsql
+   cd build/tests/etc/db/hsql
    java -cp ${jdbc.driver.jar} org.hsqldb.Server
     </fail>
     <echo message="Done." />
@@ -1267,7 +1286,7 @@
       SHUTDOWN
     </sql>
     <!-- The lock file should be deleted automatically, but just in case... -->
-    <delete file="${tests}/etc/db/hsql/jspwiki.lck" />
+    <delete file="${tests.db}/hsql/jspwiki.lck" />
     <echo message="Done." />
   </target>
 

Modified: incubator/jspwiki/trunk/etc/jspwiki.properties.tmpl
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/etc/jspwiki.properties.tmpl?rev=829488&r1=829487&r2=829488&view=diff
==============================================================================
--- incubator/jspwiki/trunk/etc/jspwiki.properties.tmpl (original)
+++ incubator/jspwiki/trunk/etc/jspwiki.properties.tmpl Sun Oct 25 03:52:19 2009
@@ -78,17 +78,6 @@
 jspwiki.usePageCache = true
 
 #
-#  Determines where wiki files are kept for FileSystemProvider
-#  and RCSFileProvider
-#
-#  If you're using Windows, then you must duplicate the backslashes.
-#  For example, use:
-#
-#  jspwiki.fileSystemProvider.pageDir = C:\\Data\\jspwiki
-#
-jspwiki.fileSystemProvider.pageDir = @pagedir@
-
-#
 #  The JSPWiki working directory.  If not set, a temporary path will
 #  be used.  You can see the location of the workdir in the logs.
 #  It is HIGHLY recommended that you set this.
@@ -101,44 +90,6 @@
 #
 #  ATTACHMENTS:
 #
-#  Use the following property to define which attachment provider
-#  you want to use.  You have basically two choices:
-#    * Set the value to BasicAttachmentProvider
-#      a simple, flat file versioning provider
-#    * Leave the value empty (or just comment the line out)
-#      the attachment functionality is disabled
-#
-jspwiki.attachmentProvider = BasicAttachmentProvider
-
-#
-#  The BasicAttachmentProvider needs to know where to store the files
-#  the user has uploaded.  It's okay to put these in the same directory
-#  as you put your text files (i.e. the pageDir setting above).
-#
-#  If you're using Windows, then you must duplicate the backslashes.
-#  For example, use:
-#
-#  jspwiki.basicAttachmentProvider.storageDir = C:\\Data\\jspwiki
-#
-jspwiki.basicAttachmentProvider.storageDir = @pagedir@
-
-#
-#  You can tell the BasicAttachmentProvider to add a flag
-#  so that browsers do not cache certain (or all) attachment
-#  types. This is useful in intranet environments. You should activate
-#  this if your users complain that their excel files are not uploaded
-#  correctly and they still do have an old version: Usually the
-#  file was uploaded correctly, but they get the locally cached version
-#  
-#  You can use regular expressions to disable the cache, e.g the
-#  following example will disable browser cache for all excel and word files
-#
-#  If you don't define this property, cache is enabled by default for
-#  all attachments
-#  
-#  jspwiki.basicAttachmentProvider.disableCache = .*\.xls|.*\.doc
-
-#
 #  You can limit the maximum size of an attachment by setting this
 #  value.  The value is in bytes, and by default all attachments
 #  are accepted.

Modified: incubator/jspwiki/trunk/src/java/org/apache/wiki/Release.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/java/org/apache/wiki/Release.java?rev=829488&r1=829487&r2=829488&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/java/org/apache/wiki/Release.java (original)
+++ incubator/jspwiki/trunk/src/java/org/apache/wiki/Release.java Sun Oct 25 03:52:19 2009
@@ -77,7 +77,7 @@
      *  <p>
      *  If the build identifier is empty, it is not added.
      */
-    public static final String     BUILD         = "169";
+    public static final String     BUILD         = "170";
 
     /**
      *  This is the generic version string you should use

Added: incubator/jspwiki/trunk/tests/etc/CommentedPropertiesTest.properties
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/tests/etc/CommentedPropertiesTest.properties?rev=829488&view=auto
==============================================================================
--- incubator/jspwiki/trunk/tests/etc/CommentedPropertiesTest.properties (added)
+++ incubator/jspwiki/trunk/tests/etc/CommentedPropertiesTest.properties Sun Oct 25 03:52:19 2009
@@ -0,0 +1,17 @@
+# This is a sample properties file with comments
+testProp1=Foo
+
+# This is a comment
+#   with two lines
+testProp2 =Bar
+
+# This is a property with no value
+testProp3=
+# Two final properties
+testProp4=FooAgain
+testProp5=BarAgain
+
+# This is a property that spans more than 1 line
+testProp6=Your new properties have been saved \
+    to jspwiki.properties.
+  
\ No newline at end of file

Added: incubator/jspwiki/trunk/tests/etc/groupdatabase.xml
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/tests/etc/groupdatabase.xml?rev=829488&view=auto
==============================================================================
--- incubator/jspwiki/trunk/tests/etc/groupdatabase.xml (added)
+++ incubator/jspwiki/trunk/tests/etc/groupdatabase.xml Sun Oct 25 03:52:19 2009
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--JSPWiki - a JSP-based WikiWiki clone.
+
+    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.  -->
+<groups>
+  <group name="TV" created="2006.06.20 at 14:50:54:000 EDT" modifier="" lastModified="2006.01.21 at 14:50:54:000 EST">
+    <member principal="Archie Bunker" />
+    <member principal="BullwinkleMoose" />
+    <member principal="Fred Friendly" />
+  </group>
+  <group name="Literature" created="2006.06.22 at 14:50:54:000 EDT" modifier="" lastModified="2006.01.23 at 14:50:54:000 EST">
+    <member principal="Charles Dickens" />
+    <member principal="Homer" />
+  </group>
+  <group name="Art" created="2006.06.24 at 14:50:54:000 EDT" modifier="" lastModified="2006.01.25 at 14:50:54:000 EST"/>
+  <group name="Admin" created="2006.06.25 at 14:50:54:000 EDT" modifier="" lastModified="2006.01.26 at 14:50:54:000 EST">
+    <member principal="Administrator" />
+  </group>
+</groups>
\ No newline at end of file

Added: incubator/jspwiki/trunk/tests/etc/jspwiki.properties
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/tests/etc/jspwiki.properties?rev=829488&view=auto
==============================================================================
--- incubator/jspwiki/trunk/tests/etc/jspwiki.properties (added)
+++ incubator/jspwiki/trunk/tests/etc/jspwiki.properties Sun Oct 25 03:52:19 2009
@@ -0,0 +1,141 @@
+`# 
+#    JSPWiki - a JSP-based WikiWiki clone.
+#
+#    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.  
+#
+############################################################################
+#
+#  Property file for tests.
+#
+#
+jspwiki.workDir = build/tests/workdir
+
+jspwiki.translatorReader.camelCaseLinks = true
+
+jspwiki.repository = priha
+
+jspwiki.breakTitleWithSpaces = true
+
+jspwiki.translatorReader.matchEnglishPlurals = true
+jspwiki.translatorReader.useOutlinkImage = false
+
+jspwiki.encoding = ISO-8859-1
+
+jspwiki.filterConfig = build/tests/classpath/WEB-INF/filters.xml
+
+jspwiki.baseURL = http://localhost/
+jspwiki.referenceStyle = relative
+jspwiki.searchProvider = BasicSearchProvider
+jspwiki.authorizer=org.apache.wiki.TestAuthorizer
+
+#
+#  Special page references.
+#
+#  The URL is relative to Wiki.jsp.  However, if you use
+#  a full, absolute URL, you can also do that.
+#
+# Example to redirect all requests to a page called 'OriginalWiki'
+# to the original wikiwiki at http://c2.com/cgi/wiki
+#
+# jspwiki.specialPage.OriginalWiki = http://c2.com/cgi/wiki
+#
+jspwiki.specialPage.RecentChanges = RecentChanges.jsp
+jspwiki.specialPage.FindPage = Search.jsp
+
+# InterWiki links The %s is replaced with the page reference (specify
+# multiple times to get multiple references).  Page references should
+# appear in format : [wiki:wikipage].  
+
+jspwiki.interWikiRef.JSPWiki = http://www.ecyrd.com/JSPWiki/Wiki.jsp?page=%s
+
+jspwiki.rss.generate = false
+
+#
+# Define which image types are inlined.
+# These are your standard glob expressions (just like in your
+# Windows or UNIX shells).
+#
+
+jspwiki.translatorReader.inlinePattern.1 = *.jpg
+jspwiki.translatorReader.inlinePattern.2 = *.png
+jspwiki.translatorReader.inlinePattern.3 = http://images.com/*
+
+#
+# Security: use standard providers for user/group auth, user management
+# and ACLs. Use a test userdatabase for storing users.
+#
+jspwiki.aclManager          = org.apache.wiki.auth.acl.DefaultAclManager
+#jspwiki.authorizer          = org.apache.wiki.auth.authorize.WebContainerAuthorizer
+jspwiki.groupdatabase = org.apache.wiki.auth.authorize.XMLGroupDatabase
+jspwiki.xmlGroupDatabaseFile = build/tests/classpath/WEB-INF/groupdatabase.xml
+jspwiki.userdatabase        = org.apache.wiki.auth.user.XMLUserDatabase
+jspwiki.xmlUserDatabaseFile = build/tests/classpath/WEB-INF/userdatabase.xml
+jspwiki.admin.user = admin
+
+jspwiki.userdatabase.datasource=jdbc/UserDatabase
+jspwiki.userdatabase.table=users
+jspwiki.userdatabase.uid=uid
+jspwiki.userdatabase.email=email
+jspwiki.userdatabase.fullName=full_name
+jspwiki.userdatabase.loginName=login_name
+jspwiki.userdatabase.password=password
+jspwiki.userdatabase.wikiName=wiki_name
+jspwiki.userdatabase.created=created
+jspwiki.userdatabase.modified=modified
+jspwiki.userdatabase.lockExpiry=lock_expiry
+jspwiki.userdatabase.attributes=attributes
+jspwiki.userdatabase.roleTable=roles
+jspwiki.userdatabase.role=role
+jspwiki.groupdatabase.datasource=jdbc/GroupDatabase
+jspwiki.groupdatabase.table=groups
+jspwiki.groupdatabase.membertable=group_members
+jspwiki.groupdatabase.created=created
+jspwiki.groupdatabase.creator=creator
+jspwiki.groupdatabase.name=name
+jspwiki.groupdatabase.member=member
+jspwiki.groupdatabase.modified=modified
+jspwiki.groupdatabase.modifier=modifier
+
+# JavaMail properties
+mail.smtp.host = 127.0.0.1
+mail.smtp.port = 25
+mail.from = JSPWiki <JS...@localhost>
+#mail.smtp.account = 
+#mail.smtp.password = 
+
+# Workflow test properties
+jspwiki.approver.workflow.saveWikiPage=
+jspwiki.approver.workflow.foo=janne
+jspwiki.approver.workflow.bar=Admin
+
+# URL Constructor
+jspwiki.urlConstructor = StripesURLConstructor
+
+# Keychain and admin password
+admin.passwordHash={SSHA}JtQ3xFdBNDuYw5R8u8nhsg5xqsUpbiZhvOoisQ==
+jspwiki.keychainPassword=Ga5ZrVe859WUPqG8
+
+# Spam inspector weights
+inspectorWeight.spam.org.apache.wiki.content.inspect.AkismetInspector=0.0
+inspectorWeight.spam.org.apache.wiki.content.inspect.BanListInspector=1.0
+inspectorWeight.spam.org.apache.wiki.content.inspect.BotTrapInspector=1.0
+inspectorWeight.spam.org.apache.wiki.content.inspect.ChangeRateInspector=1.0
+inspectorWeight.spam.org.apache.wiki.content.inspect.LinkCountInspector=1.0
+inspectorWeight.spam.org.apache.wiki.content.inspect.PatternInspector=1.0
+inspectorWeight.spam.org.apache.wiki.content.inspect.UserInspector=0.0
+spamScoreLimit=-0.5

Added: incubator/jspwiki/trunk/tests/etc/keychain
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/tests/etc/keychain?rev=829488&view=auto
==============================================================================
Binary file - no diff available.

Propchange: incubator/jspwiki/trunk/tests/etc/keychain
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Modified: incubator/jspwiki/trunk/tests/etc/log4j.properties
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/tests/etc/log4j.properties?rev=829488&r1=829487&r2=829488&view=diff
==============================================================================
--- incubator/jspwiki/trunk/tests/etc/log4j.properties (original)
+++ incubator/jspwiki/trunk/tests/etc/log4j.properties Sun Oct 25 03:52:19 2009
@@ -28,12 +28,12 @@
 log4j.appender.FileLog = org.apache.log4j.RollingFileAppender
 log4j.appender.FileLog.MaxFileSize    = 10MB
 log4j.appender.FileLog.MaxBackupIndex = 14
-log4j.appender.FileLog.File = @logfile@
+log4j.appender.FileLog.File = build/tests/jspwiki.log
 log4j.appender.FileLog.layout = org.apache.log4j.PatternLayout
 log4j.appender.FileLog.layout.ConversionPattern=%d [%t] %p %c %x - %m%n
 
 # Default logging setting for everything
-log4j.rootCategory=DEBUG,FileLog
+log4j.rootCategory=ERROR,FileLog
 
 # Log level for the Stripes framework
-log4j.logger.net.sourceforge.stripes=DEBUG
+log4j.logger.net.sourceforge.stripes=ERROR

Modified: incubator/jspwiki/trunk/tests/etc/priha.properties
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/tests/etc/priha.properties?rev=829488&r1=829487&r2=829488&view=diff
==============================================================================
--- incubator/jspwiki/trunk/tests/etc/priha.properties (original)
+++ incubator/jspwiki/trunk/tests/etc/priha.properties Sun Oct 25 03:52:19 2009
@@ -24,3 +24,4 @@
 #
 
 priha.provider.defaultProvider.workspaces = default jspwiki
+priha.provider.defaultProvider.directory = build/tests/priha

Added: incubator/jspwiki/trunk/tests/etc/urlpattern.properties
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/tests/etc/urlpattern.properties?rev=829488&view=auto
==============================================================================
--- incubator/jspwiki/trunk/tests/etc/urlpattern.properties (added)
+++ incubator/jspwiki/trunk/tests/etc/urlpattern.properties Sun Oct 25 03:52:19 2009
@@ -0,0 +1,23 @@
+# 
+#    JSPWiki - a JSP-based WikiWiki clone.
+#
+#    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.  
+#
+############################################################################
+#
+org.apache.wiki.action.ViewActionBean=/pages/{page}/{$event}

Added: incubator/jspwiki/trunk/tests/etc/userdatabase.xml
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/tests/etc/userdatabase.xml?rev=829488&view=auto
==============================================================================
--- incubator/jspwiki/trunk/tests/etc/userdatabase.xml (added)
+++ incubator/jspwiki/trunk/tests/etc/userdatabase.xml Sun Oct 25 03:52:19 2009
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="UTF-8"?><users>
+<!--JSPWiki - a JSP-based WikiWiki clone.
+
+    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.  -->
+  <user uid="-7739839977499061014" email="janne@ecyrd.com" fullName="Janne Jalkanen" loginName="janne" password="{SSHA}1WFv9OV11pD5IySgVH3sFa2VlCyYjbLrcVT/qw==" wikiName="JanneJalkanen" created="2006.06.25 at 14:50:54:000 EDT" lastModified="2006.01.26 at 14:50:54:000 EST">
+    <attributes>rO0ABXNyABFqYXZhLnV0aWwuSGFzaE1hcAUH2sHDFmDRAwACRgAKbG9hZEZhY3RvckkACXRocmVzaG9sZHhwP0AAAAAAAAx3CAAAABAAAAACdAAKYXR0cmlidXRlMXQAEXNvbWUgcmFuZG9tIHZhbHVldAAKYXR0cmlidXRlMnQADWFub3RoZXIgdmFsdWV4</attributes>
+  </user>
+  <user uid="-8629747547991531672" email="user@example.com" loginName="user" password="{SSHA}iQWmcKE8PyO965jh4+VNLYbxagaDdS0nC9GmuQ==" created="2006.06.25 at 14:50:54:000 EDT" lastModified="2006.01.26 at 14:50:54:000 EST"/>
+  <user loginName="admin" wikiName="Administrator" fullName="Administrator" email="admin@locahost" password="{SSHA}6YNKYMwXICUf5pMvYUZumgbFCxZMT2njtUQtJw==" created="2006.06.25 at 14:50:54:000 EDT" lastModified="2006.01.26 at 14:50:54:000 EST"/>
+  <user loginName="Alice" wikiName="Alice" fullName="Alice" email="alice@example.com" password="{SSHA}3V4zI5W6mT+x5NIHKI2KFQIYBdnAYKNOE9Aj+Q==" created="2006.06.25 at 14:50:54:000 EDT" lastModified="2006.01.26 at 14:50:54:000 EST"/>
+  <user loginName="Bob" wikiName="Bob" fullName="Bob" email="bob@example.com" password="{SSHA}NP3aAmiwK0gHywTe4qbY6klKDqnZ+F9ym9YiLg==" created="2006.06.25 at 14:50:54:000 EDT" lastModified="2006.01.26 at 14:50:54:000 EST"/>
+  <user loginName="Charlie" wikiName="Charlie" fullName="Charlie" email="charlie@example.com" password="{SSHA}wn81B14F9axtTVYsipQKC2OWQHlc6EcpMSe58Q==" created="2006.06.25 at 14:50:54:000 EDT" lastModified="2006.01.26 at 14:50:54:000 EST"/>
+  <user loginName="Fred" wikiName="FredFlintstone" fullName="Fred Flintstone" email="fred@example.com" password="{SSHA}iDeE9dysPUE28SWd6yeIqiIj9sIVyiMM7VnMKQ==" created="2006.06.25 at 14:50:54:000 EDT" lastModified="2006.01.26 at 14:50:54:000 EST"/>
+  <user loginName="Biff" wikiName="Biff" fullName="Biff" email="biff@example.com" password="{SSHA}xKAIienaZZHhKTGCNv5Li6lzeemaSs6ZYXTHFQ==" created="2006.06.25 at 14:50:54:000 EDT" lastModified="2006.01.26 at 14:50:54:000 EST"/>
+</users>

Modified: incubator/jspwiki/trunk/tests/java/org/apache/wiki/TestEngine.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/tests/java/org/apache/wiki/TestEngine.java?rev=829488&r1=829487&r2=829488&view=diff
==============================================================================
--- incubator/jspwiki/trunk/tests/java/org/apache/wiki/TestEngine.java (original)
+++ incubator/jspwiki/trunk/tests/java/org/apache/wiki/TestEngine.java Sun Oct 25 03:52:19 2009
@@ -233,7 +233,7 @@
     
     public static final InputStream findTestProperties()
     {
-        return findTestProperties( "/jspwiki.properties" );
+        return findTestProperties( "/WEB-INF/jspwiki.properties" );
     }
 
     public static final InputStream findTestProperties( String properties )

Modified: incubator/jspwiki/trunk/tests/java/org/apache/wiki/WikiEngineTest.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/tests/java/org/apache/wiki/WikiEngineTest.java?rev=829488&r1=829487&r2=829488&view=diff
==============================================================================
--- incubator/jspwiki/trunk/tests/java/org/apache/wiki/WikiEngineTest.java (original)
+++ incubator/jspwiki/trunk/tests/java/org/apache/wiki/WikiEngineTest.java Sun Oct 25 03:52:19 2009
@@ -704,7 +704,7 @@
     public void testOldVersionVars() throws Exception
     {
             Properties pr = new Properties();
-            pr.load( TestEngine.findTestProperties( "/jspwiki_vers.properties" ) );
+            pr.load( TestEngine.findTestProperties( "/WEB-INF/jspwiki_vers.properties" ) );
 
             m_engine.shutdown();
             m_engine = new TestEngine( pr );

Modified: incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/UserManagerTest.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/UserManagerTest.java?rev=829488&r1=829487&r2=829488&view=diff
==============================================================================
--- incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/UserManagerTest.java (original)
+++ incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/UserManagerTest.java Sun Oct 25 03:52:19 2009
@@ -66,7 +66,6 @@
     props.remove( "jspwiki.approver"+UserManager.SAVE_APPROVER );
     
     // Make sure we are using the XML user database
-    props.put( XMLUserDatabase.PROP_USERDATABASE, "tests/etc/userdatabase.xml" );
     m_engine  = new TestEngine( props );
     m_mgr = m_engine.getUserManager();
     m_db = m_mgr.getUserDatabase();
@@ -94,7 +93,6 @@
       props.put( "jspwiki.approver."+UserManager.SAVE_APPROVER, "Admin" );
       
       // Make sure we are using the XML user database
-      props.put( XMLUserDatabase.PROP_USERDATABASE, "tests/etc/userdatabase.xml" );
       m_engine.shutdown();
       m_engine  = new TestEngine( props );
       m_mgr = m_engine.getUserManager();

Modified: incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/authorize/LdapAuthorizerTest.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/authorize/LdapAuthorizerTest.java?rev=829488&r1=829487&r2=829488&view=diff
==============================================================================
--- incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/authorize/LdapAuthorizerTest.java (original)
+++ incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/authorize/LdapAuthorizerTest.java Sun Oct 25 03:52:19 2009
@@ -45,15 +45,6 @@
 
     protected void setUp() throws Exception
     {
-        // Create the Keychain
-        Keychain keychain = new Keychain();
-        keychain.load( null, "keychain-password".toCharArray() );
-        Keychain.Password password = new Keychain.Password( "password" );
-        keychain.setEntry( LdapConfig.KEYCHAIN_LDAP_BIND_PASSWORD, password );
-        File file = new File("tests/etc/WEB-INF/test-keychain" );
-        OutputStream stream = new FileOutputStream( file );
-        keychain.store( stream, "keychain-password".toCharArray() );
-
         // Create the TestEngine properties
         Properties props = new Properties();
         props.load( TestEngine.findTestProperties() );
@@ -76,8 +67,6 @@
         props.put( LdapConfig.PROPERTY_ROLE_BASE, "ou=roles,dc=jspwiki,dc=org" );
         props.put( LdapConfig.PROPERTY_IS_IN_ROLE_FILTER, "(&(&(objectClass=groupOfUniqueNames)(cn={0}))(uniqueMember={1}))" );
         props.put( LdapConfig.PROPERTY_BIND_USER, "Fred" );
-        props.put( AuthenticationManager.PROP_KEYCHAIN_PATH, "test-keychain" );
-        props.put( AuthenticationManager.PROP_KEYCHAIN_PASSWORD, "keychain-password" );
 
         m_engine = new TestEngine( props );
         assertEquals( LdapUserDatabase.class, m_engine.getUserManager().getUserDatabase().getClass() );
@@ -85,15 +74,8 @@
 
     protected void tearDown() throws Exception
     {
-        File file = new File( "tests/etc/WEB-INF/test-keychain" );
-        if( file.exists() )
-        {
-            file.delete();
-        }
-
         super.tearDown();
         m_engine.shutdown();
-
     }
 
     public void testGetRoles() throws Exception

Modified: incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/login/AnonymousLoginModuleTest.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/login/AnonymousLoginModuleTest.java?rev=829488&r1=829487&r2=829488&view=diff
==============================================================================
--- incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/login/AnonymousLoginModuleTest.java (original)
+++ incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/login/AnonymousLoginModuleTest.java Sun Oct 25 03:52:19 2009
@@ -113,7 +113,6 @@
     {
         Properties props = new Properties();
         props.load( TestEngine.findTestProperties() );
-        props.put(XMLUserDatabase.PROP_USERDATABASE, "tests/etc/userdatabase.xml");
         m_engine = new TestEngine(props);
         m_db = new XMLUserDatabase();
         m_subject = new Subject();

Modified: incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/login/CookieAssertionLoginModuleTest.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/login/CookieAssertionLoginModuleTest.java?rev=829488&r1=829487&r2=829488&view=diff
==============================================================================
--- incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/login/CookieAssertionLoginModuleTest.java (original)
+++ incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/login/CookieAssertionLoginModuleTest.java Sun Oct 25 03:52:19 2009
@@ -121,7 +121,6 @@
     {
         Properties props = new Properties();
         props.load( TestEngine.findTestProperties() );
-        props.put(XMLUserDatabase.PROP_USERDATABASE, "tests/etc/userdatabase.xml");
         m_engine = new TestEngine(props);
         m_db = new XMLUserDatabase();
         m_subject = new Subject();

Modified: incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/login/UserDatabaseLoginModuleTest.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/login/UserDatabaseLoginModuleTest.java?rev=829488&r1=829487&r2=829488&view=diff
==============================================================================
--- incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/login/UserDatabaseLoginModuleTest.java (original)
+++ incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/login/UserDatabaseLoginModuleTest.java Sun Oct 25 03:52:19 2009
@@ -124,7 +124,6 @@
     {
         Properties props = new Properties();
         props.load( TestEngine.findTestProperties() );
-        props.put(XMLUserDatabase.PROP_USERDATABASE, "tests/etc/userdatabase.xml");
         m_engine  = new TestEngine(props);
         m_db = new XMLUserDatabase();
         m_subject = new Subject();

Modified: incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/login/WebContainerLoginModuleTest.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/login/WebContainerLoginModuleTest.java?rev=829488&r1=829487&r2=829488&view=diff
==============================================================================
--- incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/login/WebContainerLoginModuleTest.java (original)
+++ incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/login/WebContainerLoginModuleTest.java Sun Oct 25 03:52:19 2009
@@ -118,7 +118,6 @@
     {
         Properties props = new Properties();
         props.load( TestEngine.findTestProperties() );
-        props.put(XMLUserDatabase.PROP_USERDATABASE, "tests/etc/userdatabase.xml");
         m_engine = new TestEngine(props);
         m_db = new XMLUserDatabase();
         m_subject = new Subject();

Modified: incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/user/XMLUserDatabaseTest.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/user/XMLUserDatabaseTest.java?rev=829488&r1=829487&r2=829488&view=diff
==============================================================================
--- incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/user/XMLUserDatabaseTest.java (original)
+++ incubator/jspwiki/trunk/tests/java/org/apache/wiki/auth/user/XMLUserDatabaseTest.java Sun Oct 25 03:52:19 2009
@@ -57,7 +57,6 @@
       super.setUp();
       Properties props = new Properties();
       props.load( TestEngine.findTestProperties() );
-      props.put(XMLUserDatabase.PROP_USERDATABASE, "tests/etc/userdatabase.xml");
       m_engine  = new TestEngine(props);
       m_db = new XMLUserDatabase();
       m_db.initialize(m_engine, props);

Modified: incubator/jspwiki/trunk/tests/java/org/apache/wiki/parser/JSPWikiMarkupParserTest.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/tests/java/org/apache/wiki/parser/JSPWikiMarkupParserTest.java?rev=829488&r1=829487&r2=829488&view=diff
==============================================================================
--- incubator/jspwiki/trunk/tests/java/org/apache/wiki/parser/JSPWikiMarkupParserTest.java (original)
+++ incubator/jspwiki/trunk/tests/java/org/apache/wiki/parser/JSPWikiMarkupParserTest.java Sun Oct 25 03:52:19 2009
@@ -2327,14 +2327,7 @@
     {
         Benchmark sw = new Benchmark();
         sw.start();
-        
-        // Create the page and save it to disk.
-        if ( !testEngine.pageExists( PAGE_NAME ) )
-        {
-            testEngine.saveText( PAGE_NAME, brokenPageText );
-        }
 
-        // Test the rendering speed
         for( int i = 0; i < 100; i++ )
         {
             translate( brokenPageText );

Modified: incubator/jspwiki/trunk/tests/java/org/apache/wiki/util/CommentedPropertiesTest.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/tests/java/org/apache/wiki/util/CommentedPropertiesTest.java?rev=829488&r1=829487&r2=829488&view=diff
==============================================================================
--- incubator/jspwiki/trunk/tests/java/org/apache/wiki/util/CommentedPropertiesTest.java (original)
+++ incubator/jspwiki/trunk/tests/java/org/apache/wiki/util/CommentedPropertiesTest.java Sun Oct 25 03:52:19 2009
@@ -39,7 +39,7 @@
 
     public void setUp() throws IOException
     {
-        InputStream in = CommentedPropertiesTest.class.getClassLoader().getResourceAsStream( "test.properties" );
+        InputStream in = CommentedPropertiesTest.class.getClassLoader().getResourceAsStream( "CommentedPropertiesTest.properties" );
         m_props.load( in );
         in.close();
     }
@@ -165,14 +165,14 @@
     public void testStore() throws Exception
     {
         // Write results to a new file
-        File outFile = createFile( "test2.properties" );
+        File outFile = createFile( "CommentedPropertiesTest2.properties" );
         OutputStream out = new FileOutputStream( outFile );
         m_props.store( out, null );
         out.close();
 
         // Load the file into new props object; should return identical strings
         Properties props2 = new CommentedProperties();
-        InputStream in = CommentedPropertiesTest.class.getClassLoader().getResourceAsStream( "test2.properties" );
+        InputStream in = CommentedPropertiesTest.class.getClassLoader().getResourceAsStream( "CommentedPropertiesTest2.properties" );
         props2.load( in );
         in.close();
         assertEquals( m_props.toString(), props2.toString() );
@@ -181,14 +181,14 @@
         m_props.remove( "testProp1" );
         m_props.remove( "testProp2" );
         m_props.remove( "testProp3" );
-        outFile = createFile( "test3.properties" );
+        outFile = createFile( "CommentedPropertiesTest3.properties" );
         out = new FileOutputStream( outFile );
         m_props.store( out, null );
         out.close();
 
         // Load the new file; should not have props1/2/3 & is shorter
         Properties props3 = new CommentedProperties();
-        in = CommentedPropertiesTest.class.getClassLoader().getResourceAsStream( "test3.properties" );
+        in = CommentedPropertiesTest.class.getClassLoader().getResourceAsStream( "CommentedPropertiesTest3.properties" );
         props3.load( in );
         in.close();
         assertNotSame( m_props.toString(), props3.toString() );
@@ -199,12 +199,12 @@
         assertTrue( props3.containsKey( "testProp5" ) );
 
         // Clean up
-        File file = getFile( "test2.properties" );
+        File file = getFile( "CommentedPropertiesTest2.properties" );
         if( file != null && file.exists() )
         {
             file.delete();
         }
-        file = getFile( "test3.properties" );
+        file = getFile( "CommentedPropertiesTest3.properties" );
         if( file != null && file.exists() )
         {
             file.delete();
@@ -213,11 +213,11 @@
 
     private File createFile( String file ) throws URISyntaxException
     {
-        // Get the test.properties file
-        URL url = CommentedPropertiesTest.class.getClassLoader().getResource( "test.properties" );
+        // Get the test properties file
+        URL url = CommentedPropertiesTest.class.getClassLoader().getResource( "CommentedPropertiesTest.properties" );
         if( url == null )
         {
-            throw new IllegalStateException( "Very odd. We can't find test.properties!" );
+            throw new IllegalStateException( "Very odd. We can't find CommentedPropertiesTest.properties!" );
         }
 
         // Construct new file in same directory
@@ -228,11 +228,11 @@
 
     private File getFile( String name )
     {
-        // Get the test.properties file
+        // Get the test properties file
         URL url = CommentedPropertiesTest.class.getClassLoader().getResource( name );
         if( url == null )
         {
-            throw new IllegalStateException( "Very odd. We can't find test.properties!" );
+            throw new IllegalStateException( "Very odd. We can't find CommentedPropertiesTest.properties!" );
         }
         // Return the file
         File file = null;