Registry / testing / camel-test-spring3

camel-test-spring3

JSON →
library2.17.7javamavenunverified

Testing library for Apache Camel with JUnit and Spring 3.x support.

<dependency> <groupId>org.apache.camel</groupId> <artifactId>camel-test-spring3</artifactId> <version>2.17.7</version> </dependency>
INSTALL
IMPORT
SIG · CAMEL-TEST-SPRING3
C
camel-test-spring3
testingjavav2.17.7
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

CamelSpringTestSupport
org.apache.camel.test.spring.CamelSpringTestSupport

Test a Camel route with Spring context

import org.apache.camel.test.spring.CamelSpringTestSupport; import org.springframework.context.support.AbstractApplicationContext; import org.springframework.context.support.ClassPathXmlApplicationContext; public class MyCamelTest extends CamelSpringTestSupport { @Override protected AbstractApplicationContext createApplicationContext() { return new ClassPathXmlApplicationContext("camel-context.xml"); } public void testRoute() { template.sendBody("direct:start", "Hello"); String result = consumer.receiveBody("mock:result", String.class); assertEquals("Hello", result); } }
Debug
Known issues
breakingDesigned for Spring 3.x; may not work with Spring 4/5 without adaptation
fix
Use camel-test-spring (without '3') for Spring 4/5 compatibility
affects: >=2.17.0
Upgrade
Version history
2.17.7latest on Maven
Audit
Dependencies

No dependency data recorded yet.

Agent activity
17 hits · last 30 days
node
14
Amazon
1
OpenAI (training)
1
Resources
camel-test-spring3 — mvn dependency:get camel-test-spring3 · libregistry