]> source.dussan.org Git - archiva.git/commitdiff
fix webapp unit tests with commenting a spring which is not used and override the...
authorOlivier Lamy <olamy@apache.org>
Fri, 19 Aug 2011 17:15:41 +0000 (17:15 +0000)
committerOlivier Lamy <olamy@apache.org>
Fri, 19 Aug 2011 17:15:41 +0000 (17:15 +0000)
git-svn-id: https://svn.apache.org/repos/asf/archiva/trunk@1159691 13f79535-47bb-0310-9956-ffa450edef68

archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/main/components-fragment.xml [deleted file]
archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/main/resources/META-INF/spring-context.xml
archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/test/resources/archiva-test.xml
archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/test/resources/spring-context.xml
archiva-modules/archiva-web/archiva-webapp/src/test/resources/META-INF/spring-context.xml [new file with mode: 0644]
archiva-modules/archiva-web/archiva-webapp/src/test/webapp/WEB-INF/feedServletTest-web.xml
archiva-modules/archiva-web/archiva-webdav/src/test/resources/WEB-INF/repository-servlet-security-test/web.xml

diff --git a/archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/main/components-fragment.xml b/archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/main/components-fragment.xml
deleted file mode 100644 (file)
index d472d5a..0000000
+++ /dev/null
@@ -1,63 +0,0 @@
-<?xml version="1.0" ?>
-<!--
-  ~ 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.
-  -->
-
-<component-set>
-  <components>
-    <!--
-     |
-     |  Repository Scanning Task Queue / Executor
-     |
-     -->
-    <component>
-      <role>org.codehaus.plexus.taskqueue.TaskQueue</role>
-      <role-hint>repository-scanning</role-hint>
-      <implementation>org.codehaus.plexus.taskqueue.DefaultTaskQueue</implementation>
-      <lifecycle-handler>plexus-configurable</lifecycle-handler>
-      <configuration>
-        <task-entry-evaluators>
-        </task-entry-evaluators>
-        <task-exit-evaluators>
-        </task-exit-evaluators>
-        <task-viability-evaluators>
-        </task-viability-evaluators>
-      </configuration>
-    </component>
-
-    <component>
-      <role>org.codehaus.plexus.taskqueue.execution.TaskQueueExecutor</role>
-      <role-hint>repository-scanning</role-hint>
-      <implementation>org.codehaus.plexus.taskqueue.execution.ThreadedTaskQueueExecutor</implementation>
-      <instantiation-strategy>singleton</instantiation-strategy>
-      <requirements>
-        <requirement>
-          <role>org.codehaus.plexus.taskqueue.execution.TaskExecutor</role>
-          <role-hint>repository-scanning</role-hint>
-        </requirement>
-        <requirement>
-          <role>org.codehaus.plexus.taskqueue.TaskQueue</role>
-          <role-hint>repository-scanning</role-hint>
-        </requirement>
-      </requirements>
-      <configuration>
-        <name>repository-scanning</name>
-      </configuration>
-    </component>
-  </components>
-</component-set>
index 2fd029c41715e9a7951902fe66a05d218827dc08..702cf13a09b4c0a0299d5c52bc620ec72f660180 100755 (executable)
@@ -1,4 +1,4 @@
-<?xml version="1.0"?>
+<?xml version="1.0" encoding="UTF-8"?>
 
 <!--
   ~ Licensed to the Apache Software Foundation (ASF) under one
   </bean>
   <alias name="archivaTaskScheduler#repository" alias="scheduler#repository"/>
 
+  <!--
+  olamy we can use this if one day we move away from the old plexus stuff :-)
+  btw comment this as it breaks unit tests in web as depending on classloader loading
+  it override beans with same name but with type org.codehaus.redback.components.scheduler.DefaultScheduler
   <task:scheduler id="scheduler" pool-size="10"/>
-
+  -->
 </beans>
\ No newline at end of file
index f921d661302eecc9fab77b697cb120f25c80d63a..0c1f93c8f45fa6abae74e6e13b5aab5cd4de6205 100644 (file)
@@ -1,4 +1,4 @@
-<?xml version="1.0" encoding="ISO-8859-1"?>
+<?xml version="1.0" encoding="UTF-8"?>
 <!--
   ~ Licensed to the Apache Software Foundation (ASF) under one
   ~ or more contributor license agreements.  See the NOTICE file
index 35596bb601991d9aa876a40056cf894515e2dcb2..8b0a94cb7a6f217c3474d0c268825fd55f2951ca 100755 (executable)
 
   <alias name="repositoryStatisticsManager#test" alias="repositoryStatisticsManager#default"/>
 
-  <!--
-    <component>
-      <role>org.codehaus.plexus.taskqueue.execution.TaskExecutor</role>
-      <role-hint>test-repository-scanning</role-hint>
-      <implementation>org.apache.archiva.scheduler.repository.ArchivaRepositoryScanningTaskExecutor
-      </implementation>
-      <requirements>
-        <requirement>
-          <role>org.apache.maven.archiva.configuration.ArchivaConfiguration</role>
-          <field-name>archivaConfiguration</field-name>
-          <role-hint>test-repository-scanning</role-hint>
-        </requirement>
-        <requirement>
-          <role>org.apache.archiva.repository.scanner.RepositoryScanner</role>
-          <field-name>repoScanner</field-name>
-        </requirement>
-        <requirement>
-          <role>org.apache.archiva.metadata.repository.stats.RepositoryStatisticsManager</role>
-        </requirement>
-        <requirement>
-          <role>org.apache.archiva.metadata.repository.RepositorySessionFactory</role>
-        </requirement>
-      </requirements>
-    </component>
-    -->
-
   <bean name="archivaConfiguration#test-repository-scanning" class="org.apache.maven.archiva.configuration.DefaultArchivaConfiguration">
     <property name="registry" ref="registry#test-configured"/>
   </bean>
diff --git a/archiva-modules/archiva-web/archiva-webapp/src/test/resources/META-INF/spring-context.xml b/archiva-modules/archiva-web/archiva-webapp/src/test/resources/META-INF/spring-context.xml
new file mode 100644 (file)
index 0000000..b589046
--- /dev/null
@@ -0,0 +1,37 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!--
+  ~ 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.
+  -->
+<beans xmlns="http://www.springframework.org/schema/beans"
+       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+       xsi:schemaLocation="http://www.springframework.org/schema/beans
+           http://www.springframework.org/schema/beans/spring-beans-3.0.xsd">
+
+  <bean name="scheduler" class="org.codehaus.redback.components.scheduler.DefaultScheduler">
+    <property name="properties">
+      <props>
+        <prop key="org.quartz.scheduler.instanceName">scheduler1</prop>
+        <prop key="org.quartz.threadPool.class">org.quartz.simpl.SimpleThreadPool</prop>
+        <prop key="org.quartz.threadPool.threadCount">2</prop>
+        <prop key="org.quartz.threadPool.threadPriority">4</prop>
+        <prop key="org.quartz.jobStore.class">org.quartz.simpl.RAMJobStore</prop>
+      </props>
+    </property>
+  </bean>
+</beans>
\ No newline at end of file
index 0e8e38ec5ee87c3e70e0729b48aff00365268f59..69ae360090f1d4234913164dcd7f117673d63be7 100644 (file)
@@ -1,4 +1,4 @@
-<?xml version="1.0" encoding="ISO-8859-1"?>
+<?xml version="1.0" encoding="UTF-8"?>
 <!--
   ~ Licensed to the Apache Software Foundation (ASF) under one
   ~ or more contributor license agreements.  See the NOTICE file
index 69ef84322060339e511719c19b3d178c39ecd12e..1897fd4be6fc8fd52a5b092d118c45ee2e4cfabf 100644 (file)
@@ -1,4 +1,4 @@
-<?xml version="1.0" encoding="ISO-8859-1"?>
+<?xml version="1.0" encoding="UTF-8"?>
 <!--
   ~ Licensed to the Apache Software Foundation (ASF) under one
   ~ or more contributor license agreements.  See the NOTICE file
@@ -40,7 +40,4 @@
     </param-value>
   </context-param>
 
-  <!--
-  target/test-classes/org/apache/maven/archiva/webdav/RepositoryServletSecurityTest.xml
-  -->
 </web-app>