roller-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From snoopd...@apache.org
Subject svn commit: r894711 [4/4] - in /roller/branches/roller_mavenized: ./ apps/planet/ apps/weblogger/ components/ planet-business/ planet-business/src/ planet-business/src/main/ planet-business/src/main/java/ planet-business/src/main/java/META-INF/ planet-...
Date Wed, 30 Dec 2009 21:14:11 GMT
Added: roller/branches/roller_mavenized/weblogger-business/src/main/resources/sql/derby.properties
URL: http://svn.apache.org/viewvc/roller/branches/roller_mavenized/weblogger-business/src/main/resources/sql/derby.properties?rev=894711&view=auto
==============================================================================
--- roller/branches/roller_mavenized/weblogger-business/src/main/resources/sql/derby.properties (added)
+++ roller/branches/roller_mavenized/weblogger-business/src/main/resources/sql/derby.properties Wed Dec 30 21:13:25 2009
@@ -0,0 +1,29 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+#  contributor license agreements.  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.  For additional information regarding
+# copyright in this work, please see the NOTICE file in the top level
+# directory of this distribution.
+
+DBTYPE=DERBY
+TEXT_SQL_TYPE=clob(102400)
+BOOLEAN_SQL_TYPE_FALSE=smallint default 0
+BOOLEAN_SQL_TYPE_TRUE=smallint default 1
+BOOLEAN_SQL_TYPE=smallint
+BOOLEAN_FALSE=0
+BOOLEAN_TRUE=1
+INDEXSIZE=
+INDEXSIZE_LARGE=
+ADDL_FK_PARAMS=
+TIMESTAMP_SQL_TYPE_NULL=timestamp
+TIMESTAMP_SQL_TYPE=timestamp
+

Added: roller/branches/roller_mavenized/weblogger-business/src/main/resources/sql/hsqldb.properties
URL: http://svn.apache.org/viewvc/roller/branches/roller_mavenized/weblogger-business/src/main/resources/sql/hsqldb.properties?rev=894711&view=auto
==============================================================================
--- roller/branches/roller_mavenized/weblogger-business/src/main/resources/sql/hsqldb.properties (added)
+++ roller/branches/roller_mavenized/weblogger-business/src/main/resources/sql/hsqldb.properties Wed Dec 30 21:13:25 2009
@@ -0,0 +1,28 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+#  contributor license agreements.  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.  For additional information regarding
+# copyright in this work, please see the NOTICE file in the top level
+# directory of this distribution.
+
+DBTYPE=HSQLDB
+TEXT_SQL_TYPE=longvarchar
+BOOLEAN_SQL_TYPE_FALSE=bit default 0
+BOOLEAN_SQL_TYPE_TRUE=bit default 1
+BOOLEAN_SQL_TYPE=bit
+BOOLEAN_FALSE=0
+BOOLEAN_TRUE=1
+INDEXSIZE=
+INDEXSIZE_LARGE=
+ADDL_FK_PARAMS=
+TIMESTAMP_SQL_TYPE_NULL=timestamp null
+TIMESTAMP_SQL_TYPE=timestamp

Added: roller/branches/roller_mavenized/weblogger-business/src/main/resources/sql/macros.vm
URL: http://svn.apache.org/viewvc/roller/branches/roller_mavenized/weblogger-business/src/main/resources/sql/macros.vm?rev=894711&view=auto
==============================================================================
--- roller/branches/roller_mavenized/weblogger-business/src/main/resources/sql/macros.vm (added)
+++ roller/branches/roller_mavenized/weblogger-business/src/main/resources/sql/macros.vm Wed Dec 30 21:13:25 2009
@@ -0,0 +1,119 @@
+
+#**
+Special macro to add table column with default null
+**#
+#macro(addColumnNull $table $column $type)
+#if ($db.DBTYPE == "ORACLE")
+    alter table $table add $column $type default null;
+#else
+    alter table $table add column $column $type default null;
+#end
+#end
+
+
+#**
+Special macro to add table column with not-null restriction and default value
+**#
+#macro(addColumnNotNull $table $column $type $default)
+#if($db.DBTYPE == "MYSQL" || $db.DBTYPE=="HSQDB")
+    alter table $table add column $column $type default $default not null;  
+#elseif ($db.DBTYPE == "POSTGRESQL")
+    alter table $table add column $column $type;
+    alter table $table alter $column set default $default;
+    update $table set $column=$default;
+    alter table $table alter $column set not null;
+#elseif ($db.DBTYPE == "HSQLDB")
+    alter table $table add column $column $type default $default not null; 
+#elseif ($db.DBTYPE == "DERBY" || $db.DBTYPE == "DB2")
+    alter table $table add column $column $type with default $default not null;
+#elseif ($db.DBTYPE == "ORACLE")
+    alter table $table add $column $type default $default not null;  
+#end
+#end
+
+
+#**
+Special macro to drop NOT NULL requirement from an 'id' column.
+**#
+#macro(dropNotNullFromTableId $table)
+#if($db.DBTYPE == "MYSQL")
+    alter table $table drop primary key;
+    alter table $table modify id varchar(48) null;
+#elseif ($db.DBTYPE == "POSTGRESQL")
+    alter table $table drop constraint "${table}_pkey";
+    alter table $table  alter column id drop not null;
+#elseif ($db.DBTYPE == "HSQLDB")
+    alter table $table alter column id varchar(48) null;
+#elseif ($db.DBTYPE == "DERBY" || $db.DBTYPE == "DB2")
+    alter table $table drop primary key;
+    alter table $table alter column id null;
+#elseif ($db.DBTYPE == "ORACLE")
+    alter table $table drop primary key; 
+#end
+#end
+
+
+#**
+Special macro to drop NOT NULL requirement from a column.
+**#
+#macro(dropNotNullFromColumn $table $colname $coltype)
+#if($db.DBTYPE == "MYSQL")
+    alter table $table modify $colname $coltype null;
+#elseif ($db.DBTYPE == "POSTGRESQL")
+    alter table $table  alter column $colname drop not null;
+#elseif ($db.DBTYPE == "HSQLDB")
+    alter table $table alter column $colname $coltype null;
+#elseif ($db.DBTYPE == "DERBY" || $db.DBTYPE == "DB2")
+    alter table $table alter column $colname null;
+#elseif ($db.DBTYPE == "ORACLE")
+    alter table $table alter column $colname null; 
+#end
+#end
+
+
+#**
+Define non-null column with default value
+**#
+#macro(columnNotNullWithDefault $columnName $columnType $defaultValue)
+#if($db.DBTYPE == "ORACLE")
+   $columnName      $columnType default '$defaultValue' not null
+#else 
+   $columnName      $columnType not null default '$defaultValue'
+#end
+#end
+
+
+#**
+Macro to account for lack of comparable long varchar in MySQL
+**#
+#macro(longtext $size) #if($db.DBTYPE == "MYSQL") text #else varchar($size) #end #end
+
+
+#macro(dropIndex $indexName $tableName)
+#if ($db.DBTYPE == "DERBY" || $db.DBTYPE == 'POSTGRESQL')
+drop index $indexName;
+#else
+drop index $indexName on $tableName;
+#end
+#end
+
+
+#macro(dropColumn $tableName $columnName)
+#if ($db.DBTYPE == "DERBY")
+-- You should alter table $tableName drop column $columnName;
+#else
+alter table $tableName drop column $columnName;
+#end
+#end
+
+
+#macro(dropTableIfExists $tableName) 
+#if ($db.DBTYPE == "DERBY")
+-- You should drop table $tableName if it exists
+#else
+drop table if exists $tableName;
+#end
+#end
+
+
+#macro(concat $s1 $s2) #if ($db.DBTYPE != "MYSQL") $s1 || $s2 #else concat($s1, $s2) #end #end

Added: roller/branches/roller_mavenized/weblogger-business/src/main/resources/sql/mssql.properties
URL: http://svn.apache.org/viewvc/roller/branches/roller_mavenized/weblogger-business/src/main/resources/sql/mssql.properties?rev=894711&view=auto
==============================================================================
--- roller/branches/roller_mavenized/weblogger-business/src/main/resources/sql/mssql.properties (added)
+++ roller/branches/roller_mavenized/weblogger-business/src/main/resources/sql/mssql.properties Wed Dec 30 21:13:25 2009
@@ -0,0 +1,28 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+#  contributor license agreements.  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.  For additional information regarding
+# copyright in this work, please see the NOTICE file in the top level
+# directory of this distribution.
+
+DBTYPE=MSSQL
+TEXT_SQL_TYPE=text
+BOOLEAN_SQL_TYPE_FALSE=bit default 0
+BOOLEAN_SQL_TYPE_TRUE=bit default 1
+BOOLEAN_SQL_TYPE=bit
+BOOLEAN_FALSE=0
+BOOLEAN_TRUE=1
+INDEXSIZE=
+INDEXSIZE_LARGE=
+ADDL_FK_PARAMS=
+TIMESTAMP_SQL_TYPE_NULL=datetime null
+TIMESTAMP_SQL_TYPE=datetime

Added: roller/branches/roller_mavenized/weblogger-business/src/main/resources/sql/mysql.properties
URL: http://svn.apache.org/viewvc/roller/branches/roller_mavenized/weblogger-business/src/main/resources/sql/mysql.properties?rev=894711&view=auto
==============================================================================
--- roller/branches/roller_mavenized/weblogger-business/src/main/resources/sql/mysql.properties (added)
+++ roller/branches/roller_mavenized/weblogger-business/src/main/resources/sql/mysql.properties Wed Dec 30 21:13:25 2009
@@ -0,0 +1,28 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+#  contributor license agreements.  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.  For additional information regarding
+# copyright in this work, please see the NOTICE file in the top level
+# directory of this distribution.
+
+DBTYPE=MYSQL
+TEXT_SQL_TYPE=text
+BOOLEAN_SQL_TYPE_FALSE=tinyint(1) default 0
+BOOLEAN_SQL_TYPE_TRUE=tinyint(1) default 1
+BOOLEAN_SQL_TYPE=tinyint(1)
+BOOLEAN_FALSE=0
+BOOLEAN_TRUE=1
+INDEXSIZE=(40)
+INDEXSIZE_LARGE=(100)
+ADDL_FK_PARAMS=    
+TIMESTAMP_SQL_TYPE_NULL=datetime NULL
+TIMESTAMP_SQL_TYPE=datetime

Added: roller/branches/roller_mavenized/weblogger-business/src/main/resources/sql/oracle.properties
URL: http://svn.apache.org/viewvc/roller/branches/roller_mavenized/weblogger-business/src/main/resources/sql/oracle.properties?rev=894711&view=auto
==============================================================================
--- roller/branches/roller_mavenized/weblogger-business/src/main/resources/sql/oracle.properties (added)
+++ roller/branches/roller_mavenized/weblogger-business/src/main/resources/sql/oracle.properties Wed Dec 30 21:13:25 2009
@@ -0,0 +1,28 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+#  contributor license agreements.  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.  For additional information regarding
+# copyright in this work, please see the NOTICE file in the top level
+# directory of this distribution.
+
+DBTYPE=ORACLE
+TEXT_SQL_TYPE=clob
+BOOLEAN_SQL_TYPE_FALSE=number(1) default 0
+BOOLEAN_SQL_TYPE_TRUE=number(1) default 1
+BOOLEAN_SQL_TYPE=number(1)
+BOOLEAN_FALSE=0
+BOOLEAN_TRUE=1
+INDEXSIZE=
+INDEXSIZE_LARGE=
+ADDL_FK_PARAMS=
+TIMESTAMP_SQL_TYPE_NULL=timestamp(2) null
+TIMESTAMP_SQL_TYPE=timestamp(2)

Added: roller/branches/roller_mavenized/weblogger-business/src/main/resources/sql/postgresql.properties
URL: http://svn.apache.org/viewvc/roller/branches/roller_mavenized/weblogger-business/src/main/resources/sql/postgresql.properties?rev=894711&view=auto
==============================================================================
--- roller/branches/roller_mavenized/weblogger-business/src/main/resources/sql/postgresql.properties (added)
+++ roller/branches/roller_mavenized/weblogger-business/src/main/resources/sql/postgresql.properties Wed Dec 30 21:13:25 2009
@@ -0,0 +1,28 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+#  contributor license agreements.  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.  For additional information regarding
+# copyright in this work, please see the NOTICE file in the top level
+# directory of this distribution.
+
+DBTYPE=POSTGRESQL
+TEXT_SQL_TYPE=text
+BOOLEAN_SQL_TYPE_FALSE=boolean default false
+BOOLEAN_SQL_TYPE_TRUE=boolean default true
+BOOLEAN_SQL_TYPE=boolean
+BOOLEAN_FALSE=false
+BOOLEAN_TRUE=true
+INDEXSIZE=
+INDEXSIZE_LARGE=
+ADDL_FK_PARAMS=
+TIMESTAMP_SQL_TYPE_NULL=timestamp(2) with time zone null
+TIMESTAMP_SQL_TYPE=timestamp(2) with time zone

Propchange: roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/business/
------------------------------------------------------------------------------
--- svn:ignore (added)
+++ svn:ignore Wed Dec 30 21:13:25 2009
@@ -0,0 +1,3 @@
+.LCKPlanetManagerTest.java~
+.LCKPlanetManagerLocalTest.java~
+.LCKWeblogEntryTest.java~

Propchange: roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/business/
------------------------------------------------------------------------------
--- svn:mergeinfo (added)
+++ svn:mergeinfo Wed Dec 30 21:13:25 2009
@@ -0,0 +1 @@
+/roller/branches/roller_mediablogging/apps/weblogger/test/java/org/apache/roller/weblogger/business:713070-782269

Modified: roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/business/IndexManagerTest.java
URL: http://svn.apache.org/viewvc/roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/business/IndexManagerTest.java?rev=894711&r1=836018&r2=894711&view=diff
==============================================================================
--- roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/business/IndexManagerTest.java (original)
+++ roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/business/IndexManagerTest.java Wed Dec 30 21:13:25 2009
@@ -30,13 +30,18 @@
 import org.apache.roller.weblogger.pojos.WeblogEntry;
 import org.apache.roller.weblogger.pojos.Weblog;
 import org.apache.roller.weblogger.pojos.WeblogCategory;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
 
 
 /**
  * Test Search Manager business layer operations.
  */
 public class IndexManagerTest extends TestCase {
-        
+    User testUser = null;
+    Weblog testWeblog = null;
+    public static Log log = LogFactory.getLog(IndexManagerTest.class);    
+
     public IndexManagerTest(String name) {
         super(name);
     }
@@ -44,52 +49,85 @@
     public static Test suite() {
         return new TestSuite(IndexManagerTest.class);
     }
+
+    /**
+     * All tests in this suite require a user and a weblog.
+     */
+    public void setUp() throws Exception {
+        
+        // setup weblogger
+        TestUtils.setupWeblogger();
+        
+        try {
+            testUser = TestUtils.setupUser("entryTestUser");
+            testWeblog = TestUtils.setupWeblog("entryTestWeblog", testUser);
+            TestUtils.endSession(true);
+
+            //WeblogManager wmgr = WebloggerFactory.getWeblogger().getWeblogManager();
+            //assertEquals(1, wmgr.getWeblogCount());
+ 
+        } catch (Exception ex) {
+            log.error("ERROR in test setup", ex);
+            throw new Exception("Test setup failed", ex);
+        }
+    }
+    
+    public void tearDown() throws Exception {
+        
+        try {
+            TestUtils.teardownWeblog(testWeblog.getId());
+            TestUtils.teardownUser(testUser.getUserName());
+            TestUtils.endSession(true);
+        } catch (Exception ex) {
+            log.error("ERROR in test teardown", ex);
+            throw new Exception("Test teardown failed", ex);
+        }
+    }
         
     public void testSearch() throws Exception {
-
-        IndexManager imgr = WebloggerFactory.getWeblogger().getIndexManager();
-
-        User user = TestUtils.setupUser("nimoy");
-        Weblog website = TestUtils.setupWeblog("trekker", user);
-        WeblogCategory cat = TestUtils.setupWeblogCategory(website, "test", null);
-        TestUtils.endSession(true);
+        WeblogEntryManager wem = WebloggerFactory.getWeblogger().getWeblogEntryManager();
 
         WeblogEntry wd1 = new WeblogEntry();            
-        wd1.setId("dummy1");
-        wd1.setAnchor("dummy1");
-        wd1.setCategory(TestUtils.getManagedWeblogCategory(cat));
-        wd1.setCreatorUserName(user.getUserName());
-        wd1.setUpdateTime(new Timestamp(System.currentTimeMillis()));
-        wd1.setPubTime(new Timestamp(System.currentTimeMillis()));
         wd1.setTitle("The Tholian Web");
-        wd1.setWebsite(TestUtils.getManagedWebsite(website));
         wd1.setText(
          "When the Enterprise attempts to ascertain the fate of the  "
         +"U.S.S. Defiant which vanished 3 weeks ago, the warp engines  "
         +"begin to lose power, and Spock reports strange sensor readings.");
+        wd1.setAnchor("dummy1");
+        wd1.setCreatorUserName(testUser.getUserName());
+        wd1.setStatus(WeblogEntry.PUBLISHED);
+        wd1.setUpdateTime(new Timestamp(System.currentTimeMillis()));
+        wd1.setPubTime(new Timestamp(System.currentTimeMillis()));
+        wd1.setWebsite(TestUtils.getManagedWebsite(testWeblog));
 
-        WebloggerFactory.getWeblogger().getWeblogEntryManager().saveWeblogEntry(wd1);
+        WeblogCategory cat = wem.getWeblogCategory(testWeblog.getDefaultCategory().getId());
+        wd1.setCategory(cat);
+
+        wem.saveWeblogEntry(wd1);
         TestUtils.endSession(true);
         wd1 = TestUtils.getManagedWeblogEntry(wd1);
 
+        IndexManager imgr = WebloggerFactory.getWeblogger().getIndexManager();
         imgr.executeIndexOperationNow(
             new AddEntryOperation(WebloggerFactory.getWeblogger(), (IndexManagerImpl)imgr, wd1));
 
         WeblogEntry wd2 = new WeblogEntry();
-        wd2.setId("dummy2");
-        wd2.setAnchor("dummy2");
-        wd2.setCategory(TestUtils.getManagedWeblogCategory(cat));
-        wd2.setCreatorUserName(user.getUserName());
-        wd2.setUpdateTime(new Timestamp(System.currentTimeMillis()));
-        wd2.setPubTime(new Timestamp(System.currentTimeMillis()));
         wd2.setTitle("A Piece of the Action");
-        wd2.setWebsite(TestUtils.getManagedWebsite(website));
         wd2.setText(
           "The crew of the Enterprise attempts to make contact with "
           +"the inhabitants of planet Sigma Iotia II, and Uhura puts Kirk "
           +"in communication with Boss Oxmyx.");
+        wd2.setAnchor("dummy2");
+        wd2.setStatus(WeblogEntry.PUBLISHED);
+        wd2.setCreatorUserName(testUser.getUserName());
+        wd2.setUpdateTime(new Timestamp(System.currentTimeMillis()));
+        wd2.setPubTime(new Timestamp(System.currentTimeMillis()));
+        wd2.setWebsite(TestUtils.getManagedWebsite(testWeblog));
+
+        cat = wem.getWeblogCategory(testWeblog.getDefaultCategory().getId());
+        wd2.setCategory(cat);
 
-        WebloggerFactory.getWeblogger().getWeblogEntryManager().saveWeblogEntry(wd2);
+        wem.saveWeblogEntry(wd2);
         TestUtils.endSession(true);
         wd2 = TestUtils.getManagedWeblogEntry(wd2);
 

Modified: roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/business/MediaFileTest.java
URL: http://svn.apache.org/viewvc/roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/business/MediaFileTest.java?rev=894711&r1=836018&r2=894711&view=diff
==============================================================================
--- roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/business/MediaFileTest.java (original)
+++ roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/business/MediaFileTest.java Wed Dec 30 21:13:25 2009
@@ -43,6 +43,8 @@
 import org.apache.roller.weblogger.pojos.MediaFileFilter.SizeFilterType;
 import org.apache.roller.weblogger.pojos.RuntimeConfigProperty;
 import org.junit.Test;
+import org.apache.roller.weblogger.util.RollerMessages;
+
 
 /**
  * Test media file related business operations.
@@ -319,7 +321,7 @@
         tags.add(tag2);
         mediaFile.setTags(tags);
 
-        mfMgr.createMediaFile(testWeblog, mediaFile);
+        mfMgr.createMediaFile(testWeblog, mediaFile, new RollerMessages());
         String id = mediaFile.getId();
         TestUtils.endSession(true);
         assertNotNull(id);
@@ -385,7 +387,7 @@
         tags.add(tag2);
         mediaFile.setTags(tags);
 
-        mfMgr.createMediaFile(testWeblog, mediaFile);
+        mfMgr.createMediaFile(testWeblog, mediaFile, new RollerMessages());
         TestUtils.endSession(true);
         assertNotNull(mediaFile.getId());
         assertNotNull(mediaFile.getId().length() > 0);
@@ -442,7 +444,7 @@
         tags.add(tag1);
         mediaFile.setTags(tags);
 
-        mfMgr.createMediaFile(testWeblog, mediaFile);
+        mfMgr.createMediaFile(testWeblog, mediaFile, new RollerMessages());
         TestUtils.endSession(true);
         assertNotNull(mediaFile.getId());
         assertNotNull(mediaFile.getId().length() > 0);
@@ -465,7 +467,7 @@
         tags.add(tag2);
         mediaFile1.setTags(tags);
 
-        mfMgr.createMediaFile(testWeblog, mediaFile1);
+        mfMgr.createMediaFile(testWeblog, mediaFile1, new RollerMessages());
         TestUtils.endSession(true);
         assertNotNull(mediaFile1.getId());
         assertNotNull(mediaFile1.getId().length() > 0);
@@ -488,7 +490,7 @@
         tags.add(tag3);
         mediaFile2.setTags(tags);
 
-        mfMgr.createMediaFile(testWeblog, mediaFile2);
+        mfMgr.createMediaFile(testWeblog, mediaFile2, new RollerMessages());
         TestUtils.endSession(true);
         assertNotNull(mediaFile2.getId());
         assertNotNull(mediaFile2.getId().length() > 0);
@@ -618,7 +620,7 @@
             mediaFile.setWeblog(testWeblog);
             mediaFile.setInputStream(getClass().getResourceAsStream(TEST_IMAGE));
             mediaFile.setContentType("image/jpeg");
-            mfMgr.createMediaFile(testWeblog, mediaFile);
+            mfMgr.createMediaFile(testWeblog, mediaFile, new RollerMessages());
             assertNotNull(mediaFile.getId());
             assertNotNull(mediaFile.getId().length() > 0);
         }
@@ -700,7 +702,7 @@
             mediaFile.setWeblog(testWeblog);
             mediaFile.setInputStream(getClass().getResourceAsStream(TEST_IMAGE));
             mediaFile.setContentType(contentTypes[i]);
-            mfMgr.createMediaFile(testWeblog, mediaFile);
+            mfMgr.createMediaFile(testWeblog, mediaFile, new RollerMessages());
             assertNotNull(mediaFile.getId());
             assertNotNull(mediaFile.getId().length() > 0);
         }
@@ -786,7 +788,7 @@
         tags.add(tag2);
         mediaFile.setTags(tags);
 
-        mfMgr.createMediaFile(testWeblog, mediaFile);
+        mfMgr.createMediaFile(testWeblog, mediaFile, new RollerMessages());
         String id = mediaFile.getId();
         TestUtils.endSession(true);
         assertNotNull(id);
@@ -854,7 +856,7 @@
         mediaFile.setLength(4000);
         mediaFile.setInputStream(getClass().getResourceAsStream(TEST_IMAGE));
         mediaFile.setContentType("image/jpeg");
-        mfMgr.createMediaFile(testWeblog, mediaFile);
+        mfMgr.createMediaFile(testWeblog, mediaFile, new RollerMessages());
 
         MediaFile mediaFile2 = new MediaFile();
         mediaFile2.setDirectory(rootDirectory);
@@ -866,7 +868,7 @@
         mediaFile2.setLength(4000);
         mediaFile2.setInputStream(getClass().getResourceAsStream(TEST_IMAGE));
         mediaFile2.setContentType("image/jpeg");
-        mfMgr.createMediaFile(testWeblog, mediaFile2);
+        mfMgr.createMediaFile(testWeblog, mediaFile2, new RollerMessages());
 
         TestUtils.endSession(true);
 
@@ -934,7 +936,7 @@
         mediaFile.setLength(4000);
         mediaFile.setInputStream(getClass().getResourceAsStream(TEST_IMAGE));
         mediaFile.setContentType("image/jpeg");
-        mfMgr.createMediaFile(testWeblog, mediaFile);
+        mfMgr.createMediaFile(testWeblog, mediaFile, new RollerMessages());
 
         MediaFile mediaFile2 = new MediaFile();
         mediaFile2.setDirectory(rootDirectory);
@@ -946,7 +948,7 @@
         mediaFile2.setLength(4000);
         mediaFile2.setInputStream(getClass().getResourceAsStream(TEST_IMAGE));
         mediaFile2.setContentType("image/jpeg");
-        mfMgr.createMediaFile(testWeblog, mediaFile2);
+        mfMgr.createMediaFile(testWeblog, mediaFile2, new RollerMessages());
 
         TestUtils.endSession(true);
 

Modified: roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/business/PlanetManagerLocalTest.java
URL: http://svn.apache.org/viewvc/roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/business/PlanetManagerLocalTest.java?rev=894711&r1=836018&r2=894711&view=diff
==============================================================================
--- roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/business/PlanetManagerLocalTest.java (original)
+++ roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/business/PlanetManagerLocalTest.java Wed Dec 30 21:13:25 2009
@@ -57,9 +57,16 @@
     public void setUp() throws Exception {
         
         try {
+            TestUtils.setupWeblogger();
+            TestUtils.setupPlanet();
+
             testUser = TestUtils.setupUser("entryTestUser");
             testWeblog = TestUtils.setupWeblog("entryTestWeblog", testUser);
-            
+            TestUtils.endSession(true);
+
+            testUser = TestUtils.getManagedUser(testUser);
+            testWeblog = TestUtils.getManagedWebsite(testWeblog);
+
             WeblogEntry testEntry1 = new WeblogEntry();
             testEntry1.setTitle("entryTestEntry1");
             testEntry1.setLink("testEntryLink1");
@@ -70,6 +77,7 @@
             testEntry1.setWebsite(testWeblog);
             testEntry1.setCreatorUserName(testUser.getUserName());
             testEntry1.setCategory(testWeblog.getDefaultCategory());
+            testEntry1.setStatus(WeblogEntry.PUBLISHED);
             WebloggerFactory.getWeblogger().getWeblogEntryManager().saveWeblogEntry(testEntry1);
 
             WeblogEntry testEntry2 = new WeblogEntry();
@@ -82,7 +90,8 @@
             testEntry2.setWebsite(testWeblog);
             testEntry2.setCreatorUserName(testUser.getUserName());
             testEntry2.setCategory(testWeblog.getDefaultCategory());
-            WebloggerFactory.getWeblogger().getWeblogEntryManager().saveWeblogEntry(testEntry1);
+            testEntry2.setStatus(WeblogEntry.PUBLISHED);
+            WebloggerFactory.getWeblogger().getWeblogEntryManager().saveWeblogEntry(testEntry2);
 
             WeblogEntry testEntry3 = new WeblogEntry();
             testEntry3.setTitle("entryTestEntry3");
@@ -94,7 +103,8 @@
             testEntry3.setWebsite(testWeblog);
             testEntry3.setCreatorUserName(testUser.getUserName());
             testEntry3.setCategory(testWeblog.getDefaultCategory());           
-            WebloggerFactory.getWeblogger().getWeblogEntryManager().saveWeblogEntry(testEntry1);
+            testEntry3.setStatus(WeblogEntry.PUBLISHED);
+            WebloggerFactory.getWeblogger().getWeblogEntryManager().saveWeblogEntry(testEntry3);
 
             TestUtils.endSession(true);
             
@@ -123,13 +133,18 @@
             // run sync task to fill aggregator with websites created by super
             SyncWebsitesTask syncTask = new SyncWebsitesTask();
             syncTask.init();
-            syncTask.run();           
+            syncTask.runTask();
             
+            Planet planetObject = planet.getPlanetById("zzz_default_planet_zzz");
+            assertNotNull(planetObject);
+            PlanetGroup group = planet.getGroup(planetObject, "all");
+            assertEquals(1, group.getSubscriptions().size());
+
             RefreshRollerPlanetTask refreshTask = new RefreshRollerPlanetTask();
-            refreshTask.run();
+            refreshTask.runTask();
             
-            Planet planetObject = planet.getPlanet("default");
-            PlanetGroup group = planet.getGroup(planetObject, "all");
+            planetObject = planet.getPlanet("default");
+            group = planet.getGroup(planetObject, "all");
             List agg = planet.getEntries(group, 0, -1);
             assertEquals(3, agg.size());
         }

Modified: roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/business/SQLScriptRunnerTest.java
URL: http://svn.apache.org/viewvc/roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/business/SQLScriptRunnerTest.java?rev=894711&r1=836018&r2=894711&view=diff
==============================================================================
--- roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/business/SQLScriptRunnerTest.java (original)
+++ roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/business/SQLScriptRunnerTest.java Wed Dec 30 21:13:25 2009
@@ -24,11 +24,23 @@
 import junit.framework.TestCase;
 import org.apache.roller.weblogger.business.startup.WebloggerStartup;
 import org.apache.roller.weblogger.business.startup.SQLScriptRunner;
+import org.apache.roller.weblogger.TestUtils;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
 
 /**
  * Test parsing and running of SQL scripts
  */
 public class SQLScriptRunnerTest extends TestCase {
+    public static Log log = LogFactory.getLog(SQLScriptRunnerTest.class);
+
+    public void setUp() {
+        try {
+            TestUtils.setupWeblogger();
+        } catch (Exception e) {
+            log.error("ERROR initializing Roller", e);
+        }
+    }
 
     public void testParseOnly() throws Exception {        
         DatabaseProvider dbp = WebloggerStartup.getDatabaseProvider();
@@ -42,7 +54,8 @@
             dbname = "mysql";
         }
         
-        String scriptPath = "WEB-INF/dbscripts/dummydb/createdb-"+dbname+".sql";
+        String scriptPath = System.getProperty("project.build.directory")
+                + "/test-classes/WEB-INF/dbscripts/dummydb/createdb-"+dbname+".sql";
         SQLScriptRunner runner = new SQLScriptRunner(scriptPath);
         assertTrue(runner != null);
         assertTrue(runner.getCommandCount() == 5);        
@@ -62,7 +75,8 @@
         
         // run script to create tables
         SQLScriptRunner create = 
-            new SQLScriptRunner("WEB-INF/dbscripts/dummydb/createdb-"+dbname+".sql");
+            new SQLScriptRunner(System.getProperty("project.build.directory")
+                    + "/test-classes/WEB-INF/dbscripts/dummydb/createdb-"+dbname+".sql");
         create.runScript(con, true);
         
         // check to ensure tables were created
@@ -71,7 +85,7 @@
         
         // drop tables
         SQLScriptRunner drop = 
-            new SQLScriptRunner("WEB-INF/dbscripts/dummydb/droptables.sql");
+            new SQLScriptRunner(System.getProperty("project.build.directory") + "/test-classes/WEB-INF/dbscripts/dummydb/droptables.sql");
         drop.runScript(con, false);
 
         // check to ensure tables were dropped

Modified: roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/business/WeblogEntryTest.java
URL: http://svn.apache.org/viewvc/roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/business/WeblogEntryTest.java?rev=894711&r1=836018&r2=894711&view=diff
==============================================================================
--- roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/business/WeblogEntryTest.java (original)
+++ roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/business/WeblogEntryTest.java Wed Dec 30 21:13:25 2009
@@ -76,6 +76,10 @@
             testUser = TestUtils.setupUser("entryTestUser");
             testWeblog = TestUtils.setupWeblog("entryTestWeblog", testUser);
             TestUtils.endSession(true);
+
+            //WeblogManager wmgr = WebloggerFactory.getWeblogger().getWeblogManager();
+            //assertEquals(1, wmgr.getWeblogCount());
+ 
         } catch (Exception ex) {
             log.error("ERROR in test setup", ex);
             throw new Exception("Test setup failed", ex);

Modified: roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/business/WeblogStatsTest.java
URL: http://svn.apache.org/viewvc/roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/business/WeblogStatsTest.java?rev=894711&r1=836018&r2=894711&view=diff
==============================================================================
--- roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/business/WeblogStatsTest.java (original)
+++ roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/business/WeblogStatsTest.java Wed Dec 30 21:13:25 2009
@@ -80,7 +80,6 @@
         
         StatCount s1 = (StatCount)list.get(0);
         assertEquals(2L, s1.getCount()); 
-        assertEquals(entry11.getId(), s1.getSubjectId());
         assertEquals(entry11.getAnchor(), s1.getSubjectNameShort());
         assertEquals(entry11.getWebsite().getHandle(), s1.getWeblogHandle());
                
@@ -90,16 +89,16 @@
     public void testGetUserNameLetterMap() throws Exception {        
         UserManager mgr = WebloggerFactory.getWeblogger().getUserManager();      
         Map map = mgr.getUserNameLetterMap();    
-        assertNotNull(map.get("a"));
-        assertNotNull(map.get("b"));
-        assertNull(map.get("c"));
+        assertNotNull(map.get("A"));
+        assertNotNull(map.get("B"));
+        assertNotNull(map.get("C"));
     }
     public void testGetWeblogLetterMap() throws Exception {        
         WeblogManager mgr = WebloggerFactory.getWeblogger().getWeblogManager();
         Map map = mgr.getWeblogHandleLetterMap();    
-        assertNotNull(map.get("a"));
-        assertNotNull(map.get("b"));
-        assertNull(map.get("c"));
+        assertNotNull(map.get("A"));
+        assertNotNull(map.get("B"));
+        assertNotNull(map.get("C"));
     }
     protected void tearDown() throws Exception {
         

Propchange: roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/planet/
------------------------------------------------------------------------------
--- svn:mergeinfo (added)
+++ svn:mergeinfo Wed Dec 30 21:13:25 2009
@@ -0,0 +1 @@
+/roller/branches/roller_mediablogging/apps/weblogger/test/java/org/apache/roller/weblogger/planet:713070-782269

Propchange: roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/util/
------------------------------------------------------------------------------
--- svn:ignore (added)
+++ svn:ignore Wed Dec 30 21:13:25 2009
@@ -0,0 +1 @@
+.LCKUtilitiesTest.java~

Propchange: roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/util/
------------------------------------------------------------------------------
--- svn:mergeinfo (added)
+++ svn:mergeinfo Wed Dec 30 21:13:25 2009
@@ -0,0 +1 @@
+/roller/branches/roller_mediablogging/apps/weblogger/test/java/org/apache/roller/weblogger/util:713070-782269

Modified: roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/util/BlacklistTest.java
URL: http://svn.apache.org/viewvc/roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/util/BlacklistTest.java?rev=894711&r1=836018&r2=894711&view=diff
==============================================================================
--- roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/util/BlacklistTest.java (original)
+++ roller/branches/roller_mavenized/weblogger-business/src/test/java/org/apache/roller/weblogger/util/BlacklistTest.java Wed Dec 30 21:13:25 2009
@@ -22,16 +22,19 @@
 import junit.framework.Test;
 import junit.framework.TestCase;
 import junit.framework.TestSuite;
-
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
 
 /**
  * Test blacklist functionality.
  */
 public class BlacklistTest extends TestCase {
+    public static Log log =    
+        LogFactory.getLog(BlacklistTest.class);  
     
     private Blacklist blacklist;
     
-    
+      
     public BlacklistTest() {
         super();
     }
@@ -50,8 +53,9 @@
         super.setUp();
         blacklist = Blacklist.getBlacklist();
         String FS = File.separator;
-        blacklist.loadBlacklistFromFile(
-                ".." + FS + "WEB-INF" + FS + "classes" + FS + "blacklist.txt");
+        String blacklistName = System.getProperty("project.build.directory") + FS + "classes" + "blacklist.txt";
+        log.info("Processing Blacklist file: " + blacklistName);
+        blacklist.loadBlacklistFromFile(blacklistName);
     }
     
     /**

Propchange: roller/branches/roller_mavenized/weblogger-business/src/test/resources/JPAEMF.properties
------------------------------------------------------------------------------
--- svn:mergeinfo (added)
+++ svn:mergeinfo Wed Dec 30 21:13:25 2009
@@ -0,0 +1 @@
+/roller/branches/roller_mediablogging/apps/weblogger/testdata/JPAEMF.properties:713070-782269

Propchange: roller/branches/roller_mavenized/weblogger-business/src/test/resources/WEB-INF/
------------------------------------------------------------------------------
--- svn:mergeinfo (added)
+++ svn:mergeinfo Wed Dec 30 21:13:25 2009
@@ -0,0 +1 @@
+/roller/branches/roller_mediablogging/apps/weblogger/testdata/WEB-INF:713070-782269

Propchange: roller/branches/roller_mavenized/weblogger-business/src/test/resources/adminapi-testdata/
------------------------------------------------------------------------------
--- svn:mergeinfo (added)
+++ svn:mergeinfo Wed Dec 30 21:13:25 2009
@@ -0,0 +1 @@
+/roller/branches/roller_mediablogging/apps/weblogger/testdata/adminapi-testdata:713070-782269

Added: roller/branches/roller_mavenized/weblogger-business/src/test/resources/org/apache/roller/weblogger/business/package.html
URL: http://svn.apache.org/viewvc/roller/branches/roller_mavenized/weblogger-business/src/test/resources/org/apache/roller/weblogger/business/package.html?rev=894711&view=auto
==============================================================================
--- roller/branches/roller_mavenized/weblogger-business/src/test/resources/org/apache/roller/weblogger/business/package.html (added)
+++ roller/branches/roller_mavenized/weblogger-business/src/test/resources/org/apache/roller/weblogger/business/package.html Wed Dec 30 21:13:25 2009
@@ -0,0 +1,26 @@
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  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.  For additional information regarding
+  copyright in this work, please see the NOTICE file in the top level
+  directory of this distribution.
+-->
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
+<html>
+<head>
+  <title></title>
+</head>
+<body>
+JUnit tests for Roller backend implementations.<br>
+</body>
+</html>

Copied: roller/branches/roller_mavenized/weblogger-business/src/test/resources/planet-custom.properties (from r836018, roller/trunk/apps/weblogger/testdata/planet-custom.properties)
URL: http://svn.apache.org/viewvc/roller/branches/roller_mavenized/weblogger-business/src/test/resources/planet-custom.properties?p2=roller/branches/roller_mavenized/weblogger-business/src/test/resources/planet-custom.properties&p1=roller/trunk/apps/weblogger/testdata/planet-custom.properties&r1=836018&r2=894711&rev=894711&view=diff
==============================================================================
--- roller/trunk/apps/weblogger/testdata/planet-custom.properties (original)
+++ roller/branches/roller_mavenized/weblogger-business/src/test/resources/planet-custom.properties Wed Dec 30 21:13:25 2009
@@ -1,6 +1,6 @@
 
 # Pluggable backend
-#guice.backend.module=org.apache.roller.weblogger.business.jpa.PlanetModule
+guice.backend.module=org.apache.roller.weblogger.planet.business.jpa.RollerPlanetModule
 
 database.configurationType=jdbc
 
@@ -9,8 +9,6 @@
 database.jdbc.username=app
 database.jdbc.password=app
 
-hibernate.dialect=org.hibernate.dialect.DerbyDialect
-
 #database.jdbc.driverClass=com.mysql.jdbc.Driver
 #database.jdbc.connectionURL=jdbc:mysql://localhost:3306/rollertest
 #database.jdbc.username=scott

Propchange: roller/branches/roller_mavenized/weblogger-business/src/test/resources/planet-custom.properties
------------------------------------------------------------------------------
--- svn:mergeinfo (added)
+++ svn:mergeinfo Wed Dec 30 21:13:25 2009
@@ -0,0 +1 @@
+/roller/branches/roller_mediablogging/apps/weblogger/testdata/planet-custom.properties:713070-782269

Copied: roller/branches/roller_mavenized/weblogger-business/src/test/resources/roller-custom.properties (from r836018, roller/trunk/apps/weblogger/testdata/roller-custom.properties)
URL: http://svn.apache.org/viewvc/roller/branches/roller_mavenized/weblogger-business/src/test/resources/roller-custom.properties?p2=roller/branches/roller_mavenized/weblogger-business/src/test/resources/roller-custom.properties&p1=roller/trunk/apps/weblogger/testdata/roller-custom.properties&r1=836018&r2=894711&rev=894711&view=diff
==============================================================================
--- roller/trunk/apps/weblogger/testdata/roller-custom.properties (original)
+++ roller/branches/roller_mavenized/weblogger-business/src/test/resources/roller-custom.properties Wed Dec 30 21:13:25 2009
@@ -19,10 +19,10 @@
 newuser.categories=
 
 # put directories in ${build.tests}
-themes.dir=themes
-search.index.dir=search-index
-uploads.dir=uploadsdir
-mediafiles.storage.dir=mediafiles
+themes.dir=${testOutputDirectory}/themes
+search.index.dir=${testOutputDirectory}/search-index
+uploads.dir=${testOutputDirectory}/uploadsdir
+mediafiles.storage.dir=${testOutputDirectory}/mediafiles
 
 # don't auto migrate during tests
 uploads.migrate.auto=false
@@ -37,10 +37,18 @@
 tasks.TestTask.leaseTime=300
 
 # logging
-log4j.category.org.apache.roller=INFO
+log4j.rootCategory=ERROR, roller
+log4j.category.org.apache.roller=ERROR
+log4j.category.net.java.roller=ERROR
+
+#log4j.category.org.apache.roller.planet.business.jpa.JPAPropertiesManagerImpl=DEBUG
+#log4j.category.org.apache.roller.weblogger.business.jpa.JPAPropertiesManagerImpl=DEBUG
+
+#log4j.category.org.apache.roller.planet.config.PlanetConfig=DEBUG
+#log4j.category.org.apache.roller.weblogger.config.WebloggerConfig=DEBUG
+
+log4j.category.org.apache.roller.weblogger.planet.tasks=DEBUG
+log4j.category.org.apache.roller.planet.business=DEBUG
+log4j.category.org.apache.roller.weblogger.planet.business=DEBUG
 
-# debug for new Roller 5.0 features: mediafile management
-log4j.category.org.apache.roller.weblogger.webservices=DEBUG
-log4j.category.org.apache.roller.weblogger.business.jpa.JPAMediaFileManagerImpl=DEBUG
-log4j.category.org.apache.roller.weblogger.business.FileContentManagerImpl=DEBUG
 

Propchange: roller/branches/roller_mavenized/weblogger-business/src/test/resources/roller-custom.properties
------------------------------------------------------------------------------
--- svn:mergeinfo (added)
+++ svn:mergeinfo Wed Dec 30 21:13:25 2009
@@ -0,0 +1 @@
+/roller/branches/roller_mediablogging/apps/weblogger/testdata/roller-custom.properties:713070-782269

Propchange: roller/branches/roller_mavenized/weblogger-business/src/test/resources/uploadsdir/
------------------------------------------------------------------------------
--- svn:mergeinfo (added)
+++ svn:mergeinfo Wed Dec 30 21:13:25 2009
@@ -0,0 +1 @@
+/roller/branches/roller_mediablogging/apps/weblogger/testdata/uploadsdir:713070-782269

Propchange: roller/branches/roller_mavenized/weblogger-web/
------------------------------------------------------------------------------
--- svn:ignore (added)
+++ svn:ignore Wed Dec 30 21:13:25 2009
@@ -0,0 +1,4 @@
+target
+.settings
+.classpath
+.project

Added: roller/branches/roller_mavenized/weblogger-web/pom.xml
URL: http://svn.apache.org/viewvc/roller/branches/roller_mavenized/weblogger-web/pom.xml?rev=894711&view=auto
==============================================================================
--- roller/branches/roller_mavenized/weblogger-web/pom.xml (added)
+++ roller/branches/roller_mavenized/weblogger-web/pom.xml Wed Dec 30 21:13:25 2009
@@ -0,0 +1,478 @@
+<project>
+
+	<modelVersion>4.0.0</modelVersion>
+
+    <parent>
+        <groupId>org.apache.roller</groupId>
+        <artifactId>roller-project</artifactId>
+        <version>5.0-BETA2-SNAPSHOT</version>
+        <relativePath>../pom.xml</relativePath>
+    </parent>
+    
+    <name>Apache Roller Weblogger Web Application</name>
+    <groupId>org.apache.roller</groupId> 
+    <artifactId>roller-weblogger-web</artifactId> 
+    <version>5.0-BETA2-SNAPSHOT</version>
+    <packaging>war</packaging>
+
+	 <dependencies>
+
+        <dependency>
+            <groupId>org.apache.roller</groupId>
+            <artifactId>roller-core</artifactId>
+            <version>5.0-BETA2-SNAPSHOT</version>
+        </dependency>
+
+       <dependency>
+            <groupId>org.apache.roller</groupId>
+            <artifactId>roller-planet-business</artifactId>
+            <version>5.0-BETA2-SNAPSHOT</version>
+        </dependency>
+
+        <dependency>
+            <groupId>org.apache.roller</groupId>
+            <artifactId>roller-weblogger-business</artifactId>
+            <version>5.0-BETA2-SNAPSHOT</version>
+        </dependency>
+
+		<dependency>
+			<groupId>org.apache.struts</groupId>
+			<artifactId>struts2-core</artifactId>
+		</dependency>
+
+        <dependency>
+            <groupId>org.apache.struts</groupId>
+            <artifactId>struts2-spring-plugin</artifactId>
+            <exclusions>
+                <exclusion>
+                    <groupId>org.springframework</groupId>
+                    <artifactId>spring-core</artifactId>
+                </exclusion>
+                <exclusion>
+                    <groupId>org.springframework</groupId>
+                    <artifactId>spring-beans</artifactId>
+                </exclusion>
+                <exclusion>
+                    <groupId>org.springframework</groupId>
+                    <artifactId>spring-context</artifactId>
+                </exclusion>
+            </exclusions>
+        </dependency> 
+
+            <!-- <dependency>
+                <groupId>com.google.inject.integration</groupId>
+                <artifactId>guice-struts2-plugin</artifactId>
+            </dependency> -->
+
+		<dependency>
+			<groupId>org.apache.struts</groupId>
+			<artifactId>struts2-tiles-plugin</artifactId>
+		</dependency>
+
+		<dependency>
+			<groupId>taglibs</groupId>
+			<artifactId>string</artifactId>
+		</dependency>
+		
+      <dependency>
+			<groupId>org.apache.tiles</groupId>
+			<artifactId>tiles-jsp</artifactId>
+		</dependency>
+
+		<dependency>
+			<groupId>org.apache.tiles</groupId>
+			<artifactId>tiles-api</artifactId>
+		</dependency>
+
+		<dependency>
+			<groupId>taglibs</groupId>
+			<artifactId>string</artifactId>
+		</dependency>		
+
+      <!-- Spring Security deps -->
+
+      <dependency>
+          <groupId>org.springframework</groupId>
+          <artifactId>spring-web</artifactId>
+          <version>2.5.6</version>
+      </dependency>
+
+      <dependency>
+          <groupId>org.springframework.ldap</groupId>
+          <artifactId>spring-ldap</artifactId>
+          <version>1.2</version>
+      </dependency>
+
+      <dependency>
+          <groupId>org.springframework.security</groupId>
+          <artifactId>spring-security-core</artifactId>
+          <version>2.0.5.RELEASE</version>
+          <exclusions>
+              <exclusion>
+                  <groupId>org.springframework</groupId>
+                  <artifactId>spring-support</artifactId>
+              </exclusion>
+          </exclusions>
+      </dependency>
+
+      <dependency>
+          <groupId>org.springframework.security</groupId>
+          <artifactId>spring-security-openid</artifactId>
+          <version>2.0.5.RELEASE</version>
+      </dependency>
+
+      <dependency>
+          <groupId>org.springframework.security</groupId>
+          <artifactId>spring-security-taglibs</artifactId>
+          <version>2.0.5.RELEASE</version>
+      </dependency>
+
+      <dependency>
+          <groupId>org.springframework.security</groupId>
+          <artifactId>spring-security-acl</artifactId>
+          <version>2.0.5.RELEASE</version>
+          <exclusions>
+              <exclusion>
+                  <groupId>org.springframework</groupId>
+                  <artifactId>spring-jdbc</artifactId>
+              </exclusion>
+          </exclusions>
+      </dependency>
+
+      <!-- OpenID deps -->
+
+      <dependency>
+          <groupId>org.openxri</groupId>
+          <artifactId>openxri-client</artifactId>
+          <version>1.2.0</version>
+      </dependency>
+
+      <dependency>
+          <groupId>org.openxri</groupId>
+          <artifactId>openxri-syntax</artifactId>
+          <version>1.2.0</version>
+      </dependency>
+
+      <dependency>
+          <groupId>org.openid4java</groupId>
+          <artifactId>openid4java</artifactId>
+          <version>0.9.5</version>
+      </dependency>
+
+      <dependency>
+          <groupId>net.sf.ehcache</groupId>
+          <artifactId>ehcache</artifactId>
+          <version>1.6.2</version>
+      </dependency>
+
+      <dependency>
+          <groupId>xml-security</groupId>
+          <artifactId>xmlsec</artifactId>
+          <version>1.3.0</version>
+      </dependency>
+
+      <dependency>
+          <groupId>xerces</groupId>
+          <artifactId>xercesImpl</artifactId>
+          <version>2.9.1</version>
+      </dependency>
+
+    <!-- Java EE deps -->
+
+		<dependency>
+			<groupId>javax.servlet</groupId>
+			<artifactId>jstl</artifactId>
+		    <!-- <scope>provided</scope> -->
+		</dependency>
+
+  		<dependency>
+			<groupId>javax.mail</groupId>
+			<artifactId>mail</artifactId>
+		    <scope>provided</scope>
+		</dependency>
+
+		<dependency>
+			<groupId>javax.servlet</groupId>
+			<artifactId>servlet-api</artifactId>
+			<scope>provided</scope>
+		</dependency>
+
+      <dependency>
+          <groupId>javax.servlet.jsp</groupId>
+          <artifactId>jsp-api</artifactId>
+          <version>2.1</version>
+		    <scope>provided</scope>
+      </dependency>
+
+    <!-- test deps -->
+
+        <dependency>
+            <groupId>org.mortbay.jetty</groupId>
+            <artifactId>jetty</artifactId>
+            <version>6.1.10</version>
+            <scope>test</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>commons-dbcp</groupId>
+            <artifactId>commons-dbcp</artifactId>
+            <version>1.2.2</version>
+			   <scope>test</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>org.apache.derby</groupId>
+            <artifactId>derbyclient</artifactId>
+			   <scope>test</scope>
+        </dependency>
+
+  	     <dependency>
+		      <groupId>simple-jndi</groupId>
+		      <artifactId>simple-jndi</artifactId>
+		      <scope>test</scope>
+	     </dependency>
+
+          <dependency>
+            <groupId>org.apache.roller</groupId>
+            <artifactId>test-utils</artifactId>
+            <version>5.0-BETA2-SNAPSHOT</version>
+			   <scope>test</scope>
+            <exclusions>
+              <exclusion>
+                  <groupId>org.apache.derby</groupId>
+                  <artifactId>derby</artifactId>
+              </exclusion>
+          </exclusions>
+      </dependency>
+
+ 		<dependency>
+			<groupId>junit</groupId>
+			<artifactId>junit</artifactId>
+			<scope>test</scope>
+		</dependency>
+
+		<dependency>
+			<groupId>org.apache.derby</groupId>
+			<artifactId>derbyclient</artifactId>
+			<scope>test</scope>
+		</dependency>
+
+  </dependencies>
+
+	<build>
+
+      <finalName>roller</finalName>
+
+		<plugins>
+
+         <plugin>
+			<groupId>org.mortbay.jetty</groupId>
+			<artifactId>maven-jetty-plugin</artifactId>
+         <configuration>
+             <jettyEnvXml>${project.build.directory}/jetty-env.xml</jettyEnvXml>
+             <systemProperties>
+                 <systemProperty>
+                     <name>roller.custom.config</name>
+                     <value>${project.build.directory}/testsetup/roller-custom.properties</value>
+                 </systemProperty>
+                 <systemProperty>
+                     <name>planet.custom.config</name>
+                     <value>${project.build.directory}/testsetup/planet-custom.properties</value>
+                 </systemProperty>
+             </systemProperties>
+         </configuration>
+         </plugin>
+
+        <plugin>
+            <artifactId>maven-resources-plugin</artifactId>
+            <executions>
+
+                <execution>
+                    <id>copy-test-properties</id>
+                    <phase>validate</phase>
+                    <goals><goal>copy-resources</goal></goals>
+                    <configuration>
+                        <outputDirectory>${basedir}/target/testsetup</outputDirectory>
+                        <resources>          
+                            <resource>
+                                <directory>src/test/resources</directory>
+                                <filtering>true</filtering>
+                            </resource>
+                        </resources>              
+                    </configuration>            
+                </execution>
+
+                 <execution>
+                    <id>copy-test-config</id>
+                    <phase>validate</phase>
+                    <goals><goal>copy-resources</goal></goals>
+                    <configuration>
+                        <outputDirectory>${basedir}/target/</outputDirectory>
+                        <resources>          
+                            <resource>
+                                <directory>src/test/resources</directory>
+                                <filtering>true</filtering>
+                            </resource>
+                        </resources>              
+                    </configuration>            
+                </execution>
+
+            </executions>
+            <configuration>
+                <includeEmptyDirs>true</includeEmptyDirs>
+            </configuration>
+        </plugin>
+
+			<plugin>
+				<artifactId>maven-surefire-plugin</artifactId>
+				<configuration>
+					<systemProperties>
+						<property>
+							<name>catalina.base</name>
+							<value>${project.build.testOutputDirectory}</value>
+						</property>
+						<property>
+							<name>context.realpath</name>
+							<value>${project.basedir}/src/main/webapp</value>
+						</property>
+						<property>
+							<name>project.build.directory</name>
+							<value>${project.build.directory}</value>
+						</property>
+					</systemProperties>
+                   <excludes>
+                       <exclude>**/TestUtils.java</exclude>
+                       <exclude>**/TestTask.java</exclude>
+                   </excludes>
+				</configuration>
+			</plugin>
+
+            <plugin>
+                <artifactId>maven-antrun-plugin</artifactId>
+                <dependencies>
+                    <dependency>
+                        <groupId>org.apache.roller</groupId>
+                        <artifactId>test-utils</artifactId>
+                        <version>5.0-BETA2-SNAPSHOT</version>
+                        <scope>test</scope>
+                    </dependency>
+                </dependencies>
+    
+                <executions>
+                    
+                    <execution>
+                        <id>startdb</id>
+                        <phase>process-test-resources</phase>
+                        <goals>
+                            <goal>run</goal>
+                        </goals>
+                        <configuration>
+                            <tasks>
+                                <taskdef name="startdb" classname="org.apache.roller.weblogger.ant.StartDerbyTask"
+                                         classpathref="maven.compile.classpath"/>
+                                <startdb database="${project.build.testOutputDirectory}/derby-system/weblogger-web"
+                                         port="3219"></startdb>
+                            </tasks>
+                        </configuration>
+                    </execution>
+    
+                    <execution>
+                        <id>stopdb</id>
+                        <phase>package</phase>
+                        <goals>
+                            <goal>run</goal>
+                        </goals>
+                        <configuration>
+                            <tasks>
+<!--
+                                <taskdef name="stopdb" classname="org.apache.roller.weblogger.ant.StopDerbyTask"
+                                         classpathref="maven.compile.classpath"/>
+                                <stopdb port="3219"></stopdb>
+                                <delete dir="${project.build.testOutputDirectory}/derby-system"/>
+-->
+                            </tasks>
+                        </configuration>
+                    </execution>
+                    
+                </executions>
+            </plugin>
+        
+            <plugin>
+                <groupId>org.codehaus.mojo</groupId>
+                <artifactId>sql-maven-plugin</artifactId>
+                <dependencies>
+                    <dependency>
+                        <groupId>org.apache.derby</groupId>
+                        <artifactId>derby</artifactId>
+                        <version>10.5.3.0_1</version>
+                    </dependency>
+                    <dependency>
+                        <groupId>org.apache.derby</groupId>
+                        <artifactId>derbyclient</artifactId>
+                        <version>10.5.3.0_1</version>
+                    </dependency>
+                </dependencies>
+                <executions>
+                
+                    <execution>
+                        <id>initdb</id>
+                        <phase>process-test-resources</phase>
+                        <goals>
+                            <goal>execute</goal>
+                        </goals>
+                        <configuration>
+                            <driver>${jdbcDriverClass}</driver>
+                            <url>jdbc:derby://localhost:3219/rollerdb;create=true</url>
+                            <username>app</username>
+                            <password>app</password>
+                            <autocommit>true</autocommit>
+                            <onError>continue</onError>
+                            <srcFiles>
+                               <srcFile>${project.build.outputDirectory}/../../../weblogger-business/target/classes/sql/droptables.sql</srcFile>
+                               <srcFile>${project.build.outputDirectory}/../../../weblogger-business/target/classes/sql/derby/createdb.sql</srcFile>
+                            </srcFiles>
+                        </configuration>
+                    </execution>
+                    
+                </executions>
+            </plugin>
+
+      </plugins>
+
+		<testResources>
+			<testResource>
+				<directory>src/test/resources</directory>
+				<filtering>true</filtering>
+			</testResource>
+		</testResources>
+
+		<resources>
+			<resource>
+				<directory>src/main/resources</directory>
+				<filtering>true</filtering>
+			</resource>
+		</resources>
+	</build>
+
+    <profiles>
+
+        <profile>
+            <id>derby-db</id>
+            <activation>
+                <activeByDefault>true</activeByDefault>
+            </activation>
+            <dependencies>
+                <dependency>
+                    <groupId>org.apache.derby</groupId>
+                    <artifactId>derby</artifactId>
+                </dependency>
+            </dependencies>
+            <properties>
+                <jdbcDriverClass>org.apache.derby.jdbc.ClientDriver</jdbcDriverClass>
+            </properties>
+        </profile>
+
+    </profiles>
+
+</project>
+

Propchange: roller/branches/roller_mavenized/weblogger-web/src/main/java/org/apache/roller/weblogger/ui/
------------------------------------------------------------------------------
--- svn:mergeinfo (added)
+++ svn:mergeinfo Wed Dec 30 21:13:25 2009
@@ -0,0 +1 @@
+/roller/branches/roller_mediablogging/apps/weblogger/src/java/org/apache/roller/weblogger/ui:713070-782269

Modified: roller/branches/roller_mavenized/weblogger-web/src/main/java/org/apache/roller/weblogger/ui/core/RollerContext.java
URL: http://svn.apache.org/viewvc/roller/branches/roller_mavenized/weblogger-web/src/main/java/org/apache/roller/weblogger/ui/core/RollerContext.java?rev=894711&r1=836018&r2=894711&view=diff
==============================================================================
--- roller/branches/roller_mavenized/weblogger-web/src/main/java/org/apache/roller/weblogger/ui/core/RollerContext.java (original)
+++ roller/branches/roller_mavenized/weblogger-web/src/main/java/org/apache/roller/weblogger/ui/core/RollerContext.java Wed Dec 30 21:13:25 2009
@@ -95,9 +95,9 @@
      * Responds to app-init event and triggers startup procedures.
      */
     public void contextInitialized(ServletContextEvent sce) {
-        
+
         // First, initialize everything that requires no database
-        
+
         // Keep a reverence to ServletContext object
         this.servletContext = sce.getServletContext();
         

Propchange: roller/branches/roller_mavenized/weblogger-web/src/main/java/org/apache/roller/weblogger/webservices/
------------------------------------------------------------------------------
--- svn:mergeinfo (added)
+++ svn:mergeinfo Wed Dec 30 21:13:25 2009
@@ -0,0 +1 @@
+/roller/branches/roller_mediablogging/apps/weblogger/src/java/org/apache/roller/weblogger/webservices:713070-782269

Copied: roller/branches/roller_mavenized/weblogger-web/src/main/resources/struts.xml (from r836018, roller/trunk/apps/weblogger/web/WEB-INF/classes/struts.xml)
URL: http://svn.apache.org/viewvc/roller/branches/roller_mavenized/weblogger-web/src/main/resources/struts.xml?p2=roller/branches/roller_mavenized/weblogger-web/src/main/resources/struts.xml&p1=roller/trunk/apps/weblogger/web/WEB-INF/classes/struts.xml&r1=836018&r2=894711&rev=894711&view=diff
==============================================================================
--- roller/trunk/apps/weblogger/web/WEB-INF/classes/struts.xml (original)
+++ roller/branches/roller_mavenized/weblogger-web/src/main/resources/struts.xml Wed Dec 30 21:13:25 2009
@@ -265,12 +265,14 @@
             <result name="success" type="tiles">.MediaFileHierarchicalView</result>
         </action>
 
+<!--
 	<action name="mediaFileSearch!*" method="{1}"
                 class="org.apache.roller.weblogger.ui.struts2.editor.MediaFileSearch">
             <result name="input" type="tiles">.MediaFileSearch</result>
             <result name="error" type="tiles">.MediaFileSearch</result>
             <result name="success" type="tiles">.MediaFileSearch</result>
         </action>
+-->
 		
 	<action name="mediaFileImageDim!*" method="{1}"
                 class="org.apache.roller.weblogger.ui.struts2.editor.MediaFileImageDim">
@@ -360,10 +362,12 @@
             <result name="error" type="chain">bookmarks</result>
         </action>
         
+        <!--
         <action name="resources!*" method="{1}"
                 class="org.apache.roller.weblogger.ui.struts2.editor.Resources">
             <result name="list" type="tiles">.Resources</result>
         </action>
+        -->
 
         <action name="weblogExport!*" method="{1}"
                 class="org.apache.roller.weblogger.ui.struts2.editor.WeblogExport">

Added: roller/branches/roller_mavenized/weblogger-web/src/main/webapp/META-INF/MANIFEST.MF
URL: http://svn.apache.org/viewvc/roller/branches/roller_mavenized/weblogger-web/src/main/webapp/META-INF/MANIFEST.MF?rev=894711&view=auto
==============================================================================
--- roller/branches/roller_mavenized/weblogger-web/src/main/webapp/META-INF/MANIFEST.MF (added)
+++ roller/branches/roller_mavenized/weblogger-web/src/main/webapp/META-INF/MANIFEST.MF Wed Dec 30 21:13:25 2009
@@ -0,0 +1,3 @@
+Manifest-Version: 1.0
+Class-Path: 
+

Modified: roller/branches/roller_mavenized/weblogger-web/src/main/webapp/WEB-INF/web.xml
URL: http://svn.apache.org/viewvc/roller/branches/roller_mavenized/weblogger-web/src/main/webapp/WEB-INF/web.xml?rev=894711&r1=836018&r2=894711&view=diff
==============================================================================
--- roller/branches/roller_mavenized/weblogger-web/src/main/webapp/WEB-INF/web.xml (original)
+++ roller/branches/roller_mavenized/weblogger-web/src/main/webapp/WEB-INF/web.xml Wed Dec 30 21:13:25 2009
@@ -577,7 +577,7 @@
     </error-page>
 
 
-    <!-- jndi resources -->
+    <!-- jndi resources 
     <resource-ref>
         <res-ref-name>jdbc/rollerdb</res-ref-name>
         <res-type>javax.sql.DataSource</res-type>
@@ -589,6 +589,7 @@
         <res-type>javax.mail.Session</res-type>
         <res-auth>Container</res-auth>
     </resource-ref>
+    -->
 
 </web-app>
 <!-- BEGIN: example config. for using Container Managed Authentication

Propchange: roller/branches/roller_mavenized/weblogger-web/src/test/java/org/apache/roller/weblogger/ui/
------------------------------------------------------------------------------
--- svn:mergeinfo (added)
+++ svn:mergeinfo Wed Dec 30 21:13:25 2009
@@ -0,0 +1 @@
+/roller/branches/roller_mediablogging/apps/weblogger/test/java/org/apache/roller/weblogger/ui:713070-782269

Modified: roller/branches/roller_mavenized/weblogger-web/src/test/java/org/apache/roller/weblogger/ui/ApplicationResourcesTest.java
URL: http://svn.apache.org/viewvc/roller/branches/roller_mavenized/weblogger-web/src/test/java/org/apache/roller/weblogger/ui/ApplicationResourcesTest.java?rev=894711&r1=836018&r2=894711&view=diff
==============================================================================
--- roller/branches/roller_mavenized/weblogger-web/src/test/java/org/apache/roller/weblogger/ui/ApplicationResourcesTest.java (original)
+++ roller/branches/roller_mavenized/weblogger-web/src/test/java/org/apache/roller/weblogger/ui/ApplicationResourcesTest.java Wed Dec 30 21:13:25 2009
@@ -31,6 +31,7 @@
 import junit.framework.TestCase;
 import junit.framework.TestSuite;
 
+
 /**
  * The purpose of this class is to verify that all messages in
  * the base ApplicationResources.properties file also appear
@@ -41,13 +42,15 @@
  * 
  * Note: we need to make sure that new property files are added to this
  * test.
+ *
+ * Note: commented out for Roller 5.0 - all translations need update
  * 
  * @author <a href="mailto:molen@mail.com">Jaap van der Molen</a>
  * @version $Revision: 1.7 $
  */
 public class ApplicationResourcesTest extends TestCase
 {
-	private String userDir = null;
+	//private String userDir = null;
 	private Properties baseProps = null; 
 
 	/**
@@ -78,12 +81,12 @@
 	protected void setUp() throws Exception
 	{
 		super.setUp();
-		userDir = System.getProperty("user.dir");
+		//userDir = System.getProperty("user.dir");
 		
 		// load base ApplicationResources.properties file
 		baseProps = new Properties();
 		baseProps.load(new FileInputStream( 
-                userDir + "/WEB-INF/classes/ApplicationResources.properties"));
+                System.getProperty("project.build.directory") + "/classes/ApplicationResources.properties"));
 	}
 
 	/**
@@ -91,7 +94,7 @@
 	 * 
 	 * @throws Exception
 	 */
-	public void testApplicationResources_nl() throws Exception
+	public void _testApplicationResources_nl() throws Exception
 	{
 		verifyResourceBundle("ApplicationResources_nl");
 	}
@@ -101,7 +104,7 @@
 	 * 
 	 * @throws Exception
 	 */
-	public void testApplicationResources_zh_cn() throws Exception
+	public void _testApplicationResources_zh_cn() throws Exception
 	{
 		verifyResourceBundle("ApplicationResources_zh_cn");
 	}
@@ -111,7 +114,7 @@
 	 * 
 	 * @throws Exception
 	 */
-	public void testApplicationResources_zh_tw() throws Exception
+	public void _testApplicationResources_zh_tw() throws Exception
 	{
 		verifyResourceBundle("ApplicationResources_zh_tw");
 	}
@@ -121,7 +124,7 @@
 	 * 
 	 * @throws Exception
 	 */
-	public void testApplicationResources_vi() throws Exception
+	public void _testApplicationResources_vi() throws Exception
 	{
 		verifyResourceBundle("ApplicationResources_vi");
 	}
@@ -146,15 +149,15 @@
 	private void verifyResourceBundle(String bundle) throws Exception
 	{
 		// verify user-dir; should end with roller
-		assertNotNull(userDir);
-		assertTrue(userDir.endsWith("roller"));
+		//assertNotNull(userDir);
+		//assertTrue(userDir.endsWith("roller"));
 		
 		// load Chinese resource file
 		Properties props = new Properties();
 		props.load(
 			new FileInputStream(
-				userDir
-					+ "/web/WEB-INF/classes/"
+				   System.getProperty("project.build.directory")
+                    + "/classes/"
 					+ bundle
 					+ ".properties"));
 

Modified: roller/branches/roller_mavenized/weblogger-web/src/test/java/org/apache/roller/weblogger/ui/rendering/util/CommentValidatorTest.java
URL: http://svn.apache.org/viewvc/roller/branches/roller_mavenized/weblogger-web/src/test/java/org/apache/roller/weblogger/ui/rendering/util/CommentValidatorTest.java?rev=894711&r1=836018&r2=894711&view=diff
==============================================================================
--- roller/branches/roller_mavenized/weblogger-web/src/test/java/org/apache/roller/weblogger/ui/rendering/util/CommentValidatorTest.java (original)
+++ roller/branches/roller_mavenized/weblogger-web/src/test/java/org/apache/roller/weblogger/ui/rendering/util/CommentValidatorTest.java Wed Dec 30 21:13:25 2009
@@ -19,14 +19,13 @@
 package org.apache.roller.weblogger.ui.rendering.util;
 
 import junit.framework.TestCase;
-import org.apache.roller.weblogger.TestUtils;
 import org.apache.roller.weblogger.pojos.WeblogEntryComment;
 import org.apache.roller.weblogger.pojos.User;
-import org.apache.roller.weblogger.pojos.WeblogCategory;
 import org.apache.roller.weblogger.pojos.WeblogEntry;
 import org.apache.roller.weblogger.pojos.Weblog;
 import org.apache.roller.weblogger.ui.rendering.plugins.comments.CommentValidationManager;
 import org.apache.roller.weblogger.util.RollerMessages;
+import org.apache.roller.weblogger.TestUtils;
 
 /**
  *

Added: roller/branches/roller_mavenized/weblogger-web/src/test/resources/jetty-env.xml
URL: http://svn.apache.org/viewvc/roller/branches/roller_mavenized/weblogger-web/src/test/resources/jetty-env.xml?rev=894711&view=auto
==============================================================================
--- roller/branches/roller_mavenized/weblogger-web/src/test/resources/jetty-env.xml (added)
+++ roller/branches/roller_mavenized/weblogger-web/src/test/resources/jetty-env.xml Wed Dec 30 21:13:25 2009
@@ -0,0 +1,16 @@
+<?xml version="1.0"?>
+<!DOCTYPE Configure PUBLIC "-//Mort Bay Consulting//DTD Configure//EN" "http://jetty.mortbay.org/configure.dtd">
+<Configure class="org.mortbay.jetty.webapp.WebAppContext">
+    <New id="rollerdb" class="org.mortbay.jetty.plus.naming.Resource">
+        <Arg>jdbc/rollerdb</Arg>
+        <Arg>
+            <New class="org.apache.commons.dbcp.BasicDataSource">
+                <Set name="driverClassName">org.apache.derby.jdbc.ClientDriver</Set>
+                <Set name="url">jdbc:derby://localhost:3219/rollerdb;create=true</Set>
+                <Set name="username">APP</Set>
+                <Set name="password">APP</Set>
+           </New>
+       </Arg>
+    </New>
+</Configure>
+        

Added: roller/branches/roller_mavenized/weblogger-web/src/test/resources/jndi.properties
URL: http://svn.apache.org/viewvc/roller/branches/roller_mavenized/weblogger-web/src/test/resources/jndi.properties?rev=894711&view=auto
==============================================================================
--- roller/branches/roller_mavenized/weblogger-web/src/test/resources/jndi.properties (added)
+++ roller/branches/roller_mavenized/weblogger-web/src/test/resources/jndi.properties Wed Dec 30 21:13:25 2009
@@ -0,0 +1,4 @@
+java.naming.factory.initial=org.osjava.sj.SimpleContextFactory
+org.osjava.sj.root=src/test/resources/simple-jndi
+org.osjava.sj.colon.replace=--
+org.osjava.sj.delimiter=/
\ No newline at end of file

Added: roller/branches/roller_mavenized/weblogger-web/src/test/resources/planet-custom.properties
URL: http://svn.apache.org/viewvc/roller/branches/roller_mavenized/weblogger-web/src/test/resources/planet-custom.properties?rev=894711&view=auto
==============================================================================
--- roller/branches/roller_mavenized/weblogger-web/src/test/resources/planet-custom.properties (added)
+++ roller/branches/roller_mavenized/weblogger-web/src/test/resources/planet-custom.properties Wed Dec 30 21:13:25 2009
@@ -0,0 +1,3 @@
+# Pluggable backend
+guice.backend.module=org.apache.roller.weblogger.planet.business.jpa.RollerPlanetModule
+

Added: roller/branches/roller_mavenized/weblogger-web/src/test/resources/roller-custom.properties
URL: http://svn.apache.org/viewvc/roller/branches/roller_mavenized/weblogger-web/src/test/resources/roller-custom.properties?rev=894711&view=auto
==============================================================================
--- roller/branches/roller_mavenized/weblogger-web/src/test/resources/roller-custom.properties (added)
+++ roller/branches/roller_mavenized/weblogger-web/src/test/resources/roller-custom.properties Wed Dec 30 21:13:25 2009
@@ -0,0 +1,52 @@
+
+#openjpa.Log=DefaultLevel=WARN, Runtime=INFO, Tool=INFO, SQL=INFO
+
+# use CMA authentication to work around Spring init issues in UI tests
+authentication.cma.enabled=true
+
+# use plain text passwords in testing
+passwds.encryption.enabled=false
+
+# we don't want to start with any folders/bookmarks for testing
+newuser.blogroll=
+
+# we don't want to start with any weblog categories for testing
+newuser.categories=
+
+# use src copy of themes for read-only access
+themes.dir=${basedir}/src/main/webapp/themes
+
+# put work in work dir
+search.index.dir          =${project.build.directory}/work/search-index
+uploads.dir               =${project.build.directory}/work/uploadsdir
+mediafiles.storage.dir    =${project.build.directory}/work/mediafiles
+log4j.appender.roller.File=${project.build.directory}/work/roller.log
+
+# don't auto migrate during tests
+uploads.migrate.auto=false
+
+# override tasks.enabled so we can add a test task
+tasks.enabled=ScheduledEntriesTask,ResetHitCountsTask,TurnoverReferersTask,PingQueueTask,TestTask
+
+# test task
+tasks.TestTask.class=org.apache.roller.weblogger.business.TestTask
+tasks.TestTask.startTime=immediate
+tasks.TestTask.interval=1800
+tasks.TestTask.leaseTime=300
+
+# logging
+log4j.rootCategory=DEBUG, roller
+#log4j.category.org.apache.roller=ERROR
+#log4j.category.net.java.roller=ERROR
+
+#log4j.category.org.apache.roller.planet.business.jpa.JPAPropertiesManagerImpl=DEBUG
+#log4j.category.org.apache.roller.weblogger.business.jpa.JPAPropertiesManagerImpl=DEBUG
+
+#log4j.category.org.apache.roller.planet.config.PlanetConfig=DEBUG
+#log4j.category.org.apache.roller.weblogger.config.WebloggerConfig=DEBUG
+
+#log4j.category.org.apache.roller.weblogger.planet.tasks=DEBUG
+#log4j.category.org.apache.roller.planet.business=DEBUG
+#log4j.category.org.apache.roller.weblogger.planet.business=DEBUG
+
+

Added: roller/branches/roller_mavenized/weblogger-web/src/test/resources/simple-jndi/java--comp/env/jdbc/default.properties
URL: http://svn.apache.org/viewvc/roller/branches/roller_mavenized/weblogger-web/src/test/resources/simple-jndi/java--comp/env/jdbc/default.properties?rev=894711&view=auto
==============================================================================
--- roller/branches/roller_mavenized/weblogger-web/src/test/resources/simple-jndi/java--comp/env/jdbc/default.properties (added)
+++ roller/branches/roller_mavenized/weblogger-web/src/test/resources/simple-jndi/java--comp/env/jdbc/default.properties Wed Dec 30 21:13:25 2009
@@ -0,0 +1,5 @@
+rollerdb/type=javax.sql.DataSource
+rollerdb/driver=${jdbcDriverClass}
+rollerdb/url=jdbc:derby://localhost:3219/rollerdb
+rollerdb/user=app
+rollerdb/password=app



Mime
View raw message