From c6969171e3d0cd3d9b0af64bb4256552fb97c00d Mon Sep 17 00:00:00 2001 From: Michel Date: Wed, 9 Dec 2020 13:57:50 +0100 Subject: [PATCH] add hint about specific junit5spring dependency I was wondering about missing dependencies for `MockMvcTestTarget`. Found it in an issue (https://github.com/pact-foundation/pact-jvm/issues/1072#issuecomment-686084768) but not in the docs --- provider/junit5spring/README.md | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/provider/junit5spring/README.md b/provider/junit5spring/README.md index 26879cfd8f..2297f92359 100644 --- a/provider/junit5spring/README.md +++ b/provider/junit5spring/README.md @@ -2,6 +2,14 @@ This module extends the base [Pact JUnit5 module](/provider/junit5/README.md). See that for more details. +## Dependency +The combined library (JUnit5 + Spring) is available on maven central using: + +group-id = au.com.dius.pact.provider +artifact-id = junit5spring +version-id = 4.1.x + +## Usage For writing Spring Pact verification tests with JUnit 5, there is an JUnit 5 Invocation Context Provider that you can use with the `@TestTemplate` annotation. This will generate a test for each interaction found for the pact files for the provider. @@ -98,4 +106,4 @@ class MockMvcTestTargetStandaloneMockMvcTestJava { ``` **Important:** Since `@WebMvcTest` starts only Spring MVC components you can't use `PactVerificationSpringProvider` -and need to fallback to `PactVerificationInvocationContextProvider` \ No newline at end of file +and need to fallback to `PactVerificationInvocationContextProvider`