You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by ac...@apache.org on 2019/08/01 06:25:25 UTC

[camel] 01/02: CAMEL-13801 - camel3 - Use @BindToRegistry wherever possible, Camel-Spring-Batch

This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git

commit 5d95ccbe0d84acef49ee8c41f248bbaf76862da6
Author: Andrea Cosentino <an...@gmail.com>
AuthorDate: Thu Aug 1 08:23:46 2019 +0200

    CAMEL-13801 - camel3 - Use @BindToRegistry wherever possible, Camel-Spring-Batch
---
 .../apache/camel/component/spring/batch/SpringBatchEndpointTest.java | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/components/camel-spring-batch/src/test/java/org/apache/camel/component/spring/batch/SpringBatchEndpointTest.java b/components/camel-spring-batch/src/test/java/org/apache/camel/component/spring/batch/SpringBatchEndpointTest.java
index e4e4ff2..f3a8ecf 100644
--- a/components/camel-spring-batch/src/test/java/org/apache/camel/component/spring/batch/SpringBatchEndpointTest.java
+++ b/components/camel-spring-batch/src/test/java/org/apache/camel/component/spring/batch/SpringBatchEndpointTest.java
@@ -28,6 +28,7 @@ import org.apache.camel.builder.RouteBuilder;
 import org.apache.camel.component.mock.MockEndpoint;
 import org.apache.camel.impl.DefaultCamelContext;
 import org.apache.camel.impl.JndiRegistry;
+import org.apache.camel.spi.Registry;
 import org.apache.camel.support.SimpleRegistry;
 import org.apache.camel.test.junit4.CamelTestSupport;
 import org.apache.commons.lang3.reflect.FieldUtils;
@@ -93,8 +94,8 @@ public class SpringBatchEndpointTest extends CamelTestSupport {
     }
 
     @Override
-    public JndiRegistry createRegistry() throws Exception {
-        JndiRegistry registry = super.createRegistry();
+    public Registry createCamelRegistry() throws Exception {
+        SimpleRegistry registry = new SimpleRegistry();
         registry.bind("jobLauncher", jobLauncher);
         registry.bind("alternativeJobLauncher", alternativeJobLauncher);
         registry.bind("mockJob", job);