Skip to content

Commit 01307c6

Browse files
committed
chore(test): apply a temporary diff to compatibility suite
Signed-off-by: JP-Ellis <josh@jpellis.me>
1 parent 7ad29bd commit 01307c6

File tree

2 files changed

+91
-0
lines changed

2 files changed

+91
-0
lines changed

.github/workflows/test.yml

+12
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,12 @@ jobs:
5555
with:
5656
submodules: true
5757

58+
- name: Apply temporary definitions update
59+
shell: bash
60+
run: |
61+
cd tests/v3/compatibility_suite
62+
patch -p1 -d definition < definition-update.diff
63+
5864
- name: Set up Python ${{ matrix.python-version }}
5965
uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c # v5
6066
with:
@@ -105,6 +111,12 @@ jobs:
105111
with:
106112
submodules: true
107113

114+
- name: Apply temporary definitions update
115+
shell: bash
116+
run: |
117+
cd tests/v3/compatibility_suite
118+
patch -p1 -d definition < definition-update.diff
119+
108120
- name: Set up Python ${{ matrix.python-version }}
109121
uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c # v5
110122
with:
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,79 @@
1+
diff --git a/features/V1/http_provider.feature b/features/V1/http_provider.feature
2+
index 94fda44..2838116 100644
3+
--- a/features/V1/http_provider.feature
4+
+++ b/features/V1/http_provider.feature
5+
@@ -118,16 +118,16 @@ Feature: Basic HTTP provider
6+
7+
Scenario: Verifies the response status code
8+
Given a provider is started that returns the response from interaction 1, with the following changes:
9+
- | status |
10+
- | 400 |
11+
+ | response |
12+
+ | 400 |
13+
And a Pact file for interaction 1 is to be verified
14+
When the verification is run
15+
Then the verification will NOT be successful
16+
And the verification results will contain a "Response status did not match" error
17+
18+
Scenario: Verifies the response headers
19+
- Given a provider is started that returns the response from interaction 1, with the following changes:
20+
- | headers |
21+
+ Given a provider is started that returns the response from interaction 5, with the following changes:
22+
+ | response headers |
23+
| 'X-TEST: Compatibility' |
24+
And a Pact file for interaction 5 is to be verified
25+
When the verification is run
26+
@@ -142,7 +142,7 @@ Feature: Basic HTTP provider
27+
28+
Scenario: Response with plain text body (negative case)
29+
Given a provider is started that returns the response from interaction 6, with the following changes:
30+
- | body |
31+
+ | response body |
32+
| Hello Compatibility Suite! |
33+
And a Pact file for interaction 6 is to be verified
34+
When the verification is run
35+
@@ -157,7 +157,7 @@ Feature: Basic HTTP provider
36+
37+
Scenario: Response with JSON body (negative case)
38+
Given a provider is started that returns the response from interaction 1, with the following changes:
39+
- | body |
40+
+ | response body |
41+
| JSON: { "one": 100, "two": "b" } |
42+
And a Pact file for interaction 1 is to be verified
43+
When the verification is run
44+
@@ -172,7 +172,7 @@ Feature: Basic HTTP provider
45+
46+
Scenario: Response with XML body (negative case)
47+
Given a provider is started that returns the response from interaction 7, with the following changes:
48+
- | body |
49+
+ | response body |
50+
| XML: <?xml version="1.0" encoding="UTF-8" ?><values><one>A</one></values> |
51+
And a Pact file for interaction 7 is to be verified
52+
When the verification is run
53+
@@ -187,7 +187,7 @@ Feature: Basic HTTP provider
54+
55+
Scenario: Response with binary body (negative case)
56+
Given a provider is started that returns the response from interaction 8, with the following changes:
57+
- | body |
58+
+ | response body |
59+
| file: spider.jpg |
60+
And a Pact file for interaction 8 is to be verified
61+
When the verification is run
62+
@@ -202,7 +202,7 @@ Feature: Basic HTTP provider
63+
64+
Scenario: Response with form post body (negative case)
65+
Given a provider is started that returns the response from interaction 9, with the following changes:
66+
- | body |
67+
+ | response body |
68+
| a=1&b=2&c=33&d=4 |
69+
And a Pact file for interaction 9 is to be verified
70+
When the verification is run
71+
@@ -217,7 +217,7 @@ Feature: Basic HTTP provider
72+
73+
Scenario: Response with multipart body (negative case)
74+
Given a provider is started that returns the response from interaction 10, with the following changes:
75+
- | body |
76+
+ | response body |
77+
| file: multipart2-body.xml |
78+
And a Pact file for interaction 10 is to be verified
79+
When the verification is run

0 commit comments

Comments
 (0)