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

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


The following commit(s) were added to refs/heads/main by this push:
     new a795c73  Polish and cleanup documentation
a795c73 is described below

commit a795c7300da5d728271b332db1cf589947a4a2f9
Author: Claus Ibsen <[email protected]>
AuthorDate: Thu Aug 26 16:16:48 2021 +0200

    Polish and cleanup documentation
---
 .../src/main/docs/test-spring-junit5.adoc          | 22 ++++++++++++++++++++++
 .../modules/others/pages/test-spring-junit5.adoc   | 22 ++++++++++++++++++++++
 2 files changed, 44 insertions(+)

diff --git 
a/components/camel-test/camel-test-spring-junit5/src/main/docs/test-spring-junit5.adoc
 
b/components/camel-test/camel-test-spring-junit5/src/main/docs/test-spring-junit5.adoc
index 9ae2670..4873069 100644
--- 
a/components/camel-test/camel-test-spring-junit5/src/main/docs/test-spring-junit5.adoc
+++ 
b/components/camel-test/camel-test-spring-junit5/src/main/docs/test-spring-junit5.adoc
@@ -128,6 +128,28 @@ This XML file is Spring XML file as shown:
 This approach supports both Camel and Spring annotations, such as 
`@Autowired`, `@DirtiesContext`, and `@ContextConfiguration`.
 However, it does NOT have feature parity with 
`org.apache.camel.test.junit5.CamelTestSupport`.
 
+== Camel test annotations
+
+The following annotations can be used with `camel-spring-junit5` unit testing.
+
+[width="100%",cols="1m,4",options="header",]
+|=======================================================================
+|Annotation |Description
+| @CamelSpringBootTest | Used for testing Camel with Spring Boot
+| @CamelSpringTest | Used for testing Camel with classic Spring XML (not 
Spring Boot)
+| @DisableJmx | Used for disabling JMX
+| @EnableRouteCoverage | Enables dumping route coverage statistic. The route 
coverage status is written as xml files in the `target/camel-route-coverage` 
directory after the test has finished. See more information at 
xref:latest@manual::camel-report-maven-plugin.adoc[Camel Maven Report Plugin].
+| @ExcludeRoutes | Indicates if certain route builder classes should be 
excluded from package scan discovery
+| @MockEndpoints | Auto-mocking of endpoints whose URIs match the provided 
filter. For more information see xref:latest@manual::advice-with.adoc[Advice 
With].
+| @MockEndpointsAndSkip | Auto-mocking of endpoints whose URIs match the 
provided filter with the added provision that the endpoints are also skipped. 
For more information see xref:latest@manual::advice-with.adoc[Advice With].
+| @ProvidesBreakpoint | Indicates that the annotated method returns a 
`Breakpoint` for use in the test. Useful for intercepting traffic to all 
endpoints or simply for setting a break point in an IDE for debugging. The 
method must be `public static`, take no arguments, and return `Breakpoint`.
+| @ShutdownTimeout | Timeout to use for 
xref:latest@manual::graceful-shutdown.adoc[shutdown]. The default is 10 seconds.
+| @UseAdviceWith | To enable testing with 
xref:latest@manual::advice-with.adoc[Advice With].
+| @UseOverridePropertiesWithPropertiesComponent | To use custom `Properties` 
with the xref:ROOT:properties-component.adoc[Properties] component. The 
annotated method must be `public` and return `Properties`.
+|=======================================================================
+
+
+
 == Migrating Camel Spring Tests from JUnit 4 to JUnit 5
 
 Find below some hints to help in migrating Camel Spring tests from JUnit 4 to 
JUnit 5.
diff --git a/docs/components/modules/others/pages/test-spring-junit5.adoc 
b/docs/components/modules/others/pages/test-spring-junit5.adoc
index cba8474..9253bc2 100644
--- a/docs/components/modules/others/pages/test-spring-junit5.adoc
+++ b/docs/components/modules/others/pages/test-spring-junit5.adoc
@@ -130,6 +130,28 @@ This XML file is Spring XML file as shown:
 This approach supports both Camel and Spring annotations, such as 
`@Autowired`, `@DirtiesContext`, and `@ContextConfiguration`.
 However, it does NOT have feature parity with 
`org.apache.camel.test.junit5.CamelTestSupport`.
 
+== Camel test annotations
+
+The following annotations can be used with `camel-spring-junit5` unit testing.
+
+[width="100%",cols="1m,4",options="header",]
+|=======================================================================
+|Annotation |Description
+| @CamelSpringBootTest | Used for testing Camel with Spring Boot
+| @CamelSpringTest | Used for testing Camel with classic Spring XML (not 
Spring Boot)
+| @DisableJmx | Used for disabling JMX
+| @EnableRouteCoverage | Enables dumping route coverage statistic. The route 
coverage status is written as xml files in the `target/camel-route-coverage` 
directory after the test has finished. See more information at 
xref:latest@manual::camel-report-maven-plugin.adoc[Camel Maven Report Plugin].
+| @ExcludeRoutes | Indicates if certain route builder classes should be 
excluded from package scan discovery
+| @MockEndpoints | Auto-mocking of endpoints whose URIs match the provided 
filter. For more information see xref:latest@manual::advice-with.adoc[Advice 
With].
+| @MockEndpointsAndSkip | Auto-mocking of endpoints whose URIs match the 
provided filter with the added provision that the endpoints are also skipped. 
For more information see xref:latest@manual::advice-with.adoc[Advice With].
+| @ProvidesBreakpoint | Indicates that the annotated method returns a 
`Breakpoint` for use in the test. Useful for intercepting traffic to all 
endpoints or simply for setting a break point in an IDE for debugging. The 
method must be `public static`, take no arguments, and return `Breakpoint`.
+| @ShutdownTimeout | Timeout to use for 
xref:latest@manual::graceful-shutdown.adoc[shutdown]. The default is 10 seconds.
+| @UseAdviceWith | To enable testing with 
xref:latest@manual::advice-with.adoc[Advice With].
+| @UseOverridePropertiesWithPropertiesComponent | To use custom `Properties` 
with the xref:ROOT:properties-component.adoc[Properties] component. The 
annotated method must be `public` and return `Properties`.
+|=======================================================================
+
+
+
 == Migrating Camel Spring Tests from JUnit 4 to JUnit 5
 
 Find below some hints to help in migrating Camel Spring tests from JUnit 4 to 
JUnit 5.

Reply via email to