diff --git a/1.2.x/multi/multi__contract_dsl.html b/1.2.x/multi/multi__contract_dsl.html index 17d6f7e67f..a339ff92a9 100644 --- a/1.2.x/multi/multi__contract_dsl.html +++ b/1.2.x/multi/multi__contract_dsl.html @@ -94,7 +94,7 @@ response: regex: bar - key: foo3 command: andMeToo($it)
![]() | Tip |
|---|---|
You can compile contracts to stubs mapping using standalone maven command:
- |
![]() | Warning |
|---|---|
Spring Cloud Contract Verifier does not properly support XML. Please use JSON or
+ |
![]() | Warning |
|---|---|
Spring Cloud Contract Verifier does not properly support XML. Please use JSON or help us implement this feature. |
![]() | Warning | ||
|---|---|---|---|
The support for verifying the size of JSON arrays is experimental. If you want
to turn it on, please set the value of the following system property to └──
│ └── contract2.groovy
└── mappings
└── mapping.jsonBy maintaining this structure classpath gets scanned and you can profit from the messaging / -HTTP stubs without the need to download artifacts.
You can set the following options to the main class: -c, --classifier Suffix for the jar containing stubs (e. g. 'stubs' if the stub jar would have a 'stubs' classifier for stubs: foobar-stubs ). Defaults to 'stubs' @@ -384,7 +380,6 @@ its methods as presented below:@AutoConfigureStubRunner(mappingsOutputFolder = "target/outputmappings/") -@DirtiesContext @ActiveProfiles("test") class StubRunnerConfigurationSpec extends Specification { @@ -662,7 +657,6 @@ Or set the test as follows:@AutoConfigureStubRunner(ids = "org.springframework.cloud.contract.verifier.stubs:producerWithMultipleConsumers", repositoryRoot = "classpath:m2repo/repository/", stubsPerConsumer = true) -@DirtiesContext class StubRunnerStubsPerConsumerSpec extends Specification { ... } Since you are developing your stub, you need to be sure that it actually resembles your @@ -443,7 +442,6 @@ collaborators. (Optional step) Because you’re playing with the collaborato can also provide the offline work switch. @RunWith(SpringRunner.class) @SpringBootTest(webEnvironment=WebEnvironment.NONE) @AutoConfigureStubRunner(ids = {"com.example:http-server-dsl:+:stubs:6565"}, workOffline = true) -@DirtiesContext public class LoanApplicationServiceTests { Now, when you run your tests, you see something like this: 2016-07-19 14:22:25.403 INFO 41050 --- [ main] o.s.c.c.stubrunner.AetherStubDownloader : Desired version is + - will try to resolve the latest version 2016-07-19 14:22:25.438 INFO 41050 --- [ main] o.s.c.c.stubrunner.AetherStubDownloader : Resolved version is 0.0.1-SNAPSHOT 2016-07-19 14:22:25.439 INFO 41050 --- [ main] o.s.c.c.stubrunner.AetherStubDownloader : Resolving artifact com.example:http-server:jar:stubs:0.0.1-SNAPSHOT using remote repositories [] diff --git a/1.2.x/multi/multi_spring-cloud-contract.html b/1.2.x/multi/multi_spring-cloud-contract.html index 94bff9a593..ce7b49d6d4 100644 --- a/1.2.x/multi/multi_spring-cloud-contract.html +++ b/1.2.x/multi/multi_spring-cloud-contract.html @@ -1,3 +1,3 @@ - |