@@ -15,7 +15,7 @@ The library is available on maven central using:
15
15
16
16
### Using the base ConsumerPactTest
17
17
18
- To write a pact spec extend ConsumerPactTestMk2 . This base class defines the following four methods which must be
18
+ To write a pact spec extend ConsumerPactTest . This base class defines the following four methods which must be
19
19
overridden in your test class.
20
20
21
21
* * providerName:* Returns the name of the API provider that Pact will mock
@@ -39,7 +39,7 @@ import java.util.Map;
39
39
40
40
import static org.junit.Assert.assertEquals ;
41
41
42
- public class ExampleJavaConsumerPactTest extends ConsumerPactTestMk2 {
42
+ public class ExampleJavaConsumerPactTest extends ConsumerPactTest {
43
43
44
44
@Override
45
45
protected RequestResponsePact createFragment (PactDslWithProvider builder ) {
@@ -101,7 +101,7 @@ and then add the rule:
101
101
102
102
``` java
103
103
@Rule
104
- public PactProviderRuleMk2 mockProvider = new PactProviderRuleMk2 (" test_provider" , " localhost" , 8080 , this );
104
+ public PactProviderRule mockProvider = new PactProviderRule (" test_provider" , " localhost" , 8080 , this );
105
105
```
106
106
107
107
The hostname and port are optional. If left out, it will default to 127.0.0.1 and a random available port. You can get
@@ -691,11 +691,11 @@ To have your consumer tests generate V2 format pacts, you can set the specificat
691
691
}
692
692
```
693
693
694
- If you are using the ` PactProviderRuleMk2 ` , you can pass the version into the constructor for the rule.
694
+ If you are using the ` PactProviderRule ` , you can pass the version into the constructor for the rule.
695
695
696
696
``` java
697
697
@Rule
698
- public PactProviderRuleMk2 mockTestProvider = new PactProviderRuleMk2 (" test_provider" , PactSpecVersion . V2 , this );
698
+ public PactProviderRule mockTestProvider = new PactProviderRule (" test_provider" , PactSpecVersion . V2 , this );
699
699
```
700
700
701
701
## Consumer test for a message consumer
0 commit comments