pacto 0.3.1 → 0.4.0.rc1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +3 -0
- data/.rubocop.yml +29 -7
- data/.travis.yml +8 -1
- data/CONTRIBUTING.md +3 -6
- data/Gemfile +13 -2
- data/Guardfile +4 -4
- data/Procfile +1 -0
- data/README.md +47 -13
- data/Rakefile +66 -19
- data/TODO.md +33 -10
- data/bin/pacto +4 -0
- data/changelog.md +30 -0
- data/docs/configuration.md +69 -0
- data/docs/consumer.md +18 -0
- data/docs/cops.md +39 -0
- data/docs/forensics.md +66 -0
- data/docs/generation.md +65 -0
- data/docs/rake_tasks.md +10 -0
- data/docs/rspec.md +0 -0
- data/docs/samples.md +133 -0
- data/docs/server.md +34 -0
- data/docs/server_cli.md +18 -0
- data/docs/stenographer.md +20 -0
- data/features/configuration/strict_matchers.feature +10 -10
- data/features/evolve/existing_services.feature +12 -10
- data/features/generate/generation.feature +11 -11
- data/features/steps/pacto_steps.rb +17 -12
- data/features/stub/templates.feature +4 -4
- data/features/support/env.rb +21 -9
- data/features/validate/meta_validation.feature +9 -17
- data/features/validate/validation.feature +5 -6
- data/lib/pacto.rb +41 -33
- data/lib/pacto/actor.rb +5 -0
- data/lib/pacto/actors/from_examples.rb +67 -0
- data/lib/pacto/actors/json_generator.rb +20 -0
- data/lib/pacto/cli.rb +75 -0
- data/lib/pacto/cli/helpers.rb +20 -0
- data/lib/pacto/consumer.rb +80 -0
- data/lib/pacto/consumer/faraday_driver.rb +34 -0
- data/lib/pacto/contract.rb +48 -20
- data/lib/pacto/contract_builder.rb +125 -0
- data/lib/pacto/contract_factory.rb +31 -12
- data/lib/pacto/contract_files.rb +1 -0
- data/lib/pacto/contract_set.rb +12 -0
- data/lib/pacto/cops.rb +46 -0
- data/lib/pacto/cops/body_cop.rb +23 -0
- data/lib/pacto/cops/request_body_cop.rb +10 -0
- data/lib/pacto/cops/response_body_cop.rb +10 -0
- data/lib/pacto/{validators/response_header_validator.rb → cops/response_header_cop.rb} +9 -15
- data/lib/pacto/cops/response_status_cop.rb +18 -0
- data/lib/pacto/core/configuration.rb +16 -5
- data/lib/pacto/core/contract_registry.rb +13 -32
- data/lib/pacto/core/hook.rb +1 -0
- data/lib/pacto/core/http_middleware.rb +23 -0
- data/lib/pacto/core/investigation_registry.rb +60 -0
- data/lib/pacto/core/modes.rb +1 -0
- data/lib/pacto/core/pacto_request.rb +59 -0
- data/lib/pacto/core/pacto_response.rb +41 -0
- data/lib/pacto/dash.rb +9 -0
- data/lib/pacto/erb_processor.rb +1 -0
- data/lib/pacto/exceptions/invalid_contract.rb +1 -0
- data/lib/pacto/extensions.rb +3 -16
- data/lib/pacto/forensics/investigation_filter.rb +90 -0
- data/lib/pacto/forensics/investigation_matcher.rb +80 -0
- data/lib/pacto/generator.rb +31 -53
- data/lib/pacto/generator/filters.rb +8 -7
- data/lib/pacto/generator/hint.rb +26 -0
- data/lib/pacto/generator/native_contract_generator.rb +74 -0
- data/lib/pacto/hooks/erb_hook.rb +2 -1
- data/lib/pacto/investigation.rb +49 -0
- data/lib/pacto/logger.rb +1 -0
- data/lib/pacto/meta_schema.rb +12 -6
- data/lib/pacto/native_contract_factory.rb +60 -0
- data/lib/pacto/observers/stenographer.rb +42 -0
- data/lib/pacto/provider.rb +27 -0
- data/lib/pacto/rake_task.rb +25 -70
- data/lib/pacto/request_clause.rb +31 -29
- data/lib/pacto/request_pattern.rb +20 -3
- data/lib/pacto/resettable.rb +22 -0
- data/lib/pacto/response_clause.rb +5 -12
- data/lib/pacto/rspec.rb +38 -31
- data/lib/pacto/server.rb +4 -0
- data/lib/pacto/stubs/uri_pattern.rb +21 -11
- data/lib/pacto/stubs/webmock_adapter.rb +69 -34
- data/lib/pacto/swagger_contract_factory.rb +90 -0
- data/lib/pacto/test_helper.rb +37 -0
- data/lib/pacto/ui.rb +32 -2
- data/lib/pacto/uri.rb +2 -1
- data/lib/pacto/version.rb +2 -1
- data/pacto-server.gemspec +24 -0
- data/pacto.gemspec +13 -9
- data/resources/contract_schema.json +46 -18
- data/resources/draft-04.json +150 -0
- data/sample_apis/album/cover_api.rb +12 -0
- data/sample_apis/config.ru +25 -0
- data/sample_apis/echo_api.rb +26 -0
- data/sample_apis/files_api.rb +50 -0
- data/sample_apis/hello_api.rb +14 -0
- data/sample_apis/ping_api.rb +11 -0
- data/sample_apis/reverse_api.rb +20 -0
- data/samples/README.md +11 -0
- data/samples/Rakefile +2 -0
- data/samples/configuration.rb +33 -0
- data/samples/consumer.rb +15 -0
- data/samples/contracts/README.md +1 -0
- data/samples/contracts/contract.js +93 -0
- data/samples/contracts/get_album_cover.json +48 -0
- data/samples/contracts/localhost/api/echo.json +37 -0
- data/samples/contracts/localhost/api/ping.json +38 -0
- data/samples/cops.rb +30 -0
- data/samples/forensics.rb +54 -0
- data/samples/generation.rb +48 -0
- data/samples/rake_tasks.sh +7 -0
- data/samples/rspec.rb +1 -0
- data/samples/samples.rb +92 -0
- data/samples/scripts/bootstrap +2 -0
- data/samples/scripts/wrapper +11 -0
- data/samples/server.rb +24 -0
- data/samples/server_cli.sh +12 -0
- data/samples/stenographer.rb +17 -0
- data/spec/coveralls_helper.rb +1 -0
- data/spec/fabricators/contract_fabricator.rb +94 -0
- data/spec/fabricators/http_fabricator.rb +48 -0
- data/spec/fabricators/webmock_fabricator.rb +24 -0
- data/spec/{unit/data → fixtures/contracts}/contract.json +2 -2
- data/spec/fixtures/contracts/contract_with_examples.json +58 -0
- data/spec/{unit/data → fixtures/contracts}/simple_contract.json +5 -3
- data/spec/{integration/data → fixtures/contracts}/strict_contract.json +5 -3
- data/spec/{integration/data → fixtures/contracts}/templating_contract.json +3 -2
- data/spec/{integration/data/simple_contract.json → fixtures/deprecated_contracts/deprecated_contract.json} +2 -1
- data/spec/fixtures/swagger/petstore.yaml +101 -0
- data/spec/integration/e2e_spec.rb +19 -20
- data/spec/integration/forensics/integration_matcher_spec.rb +90 -0
- data/spec/integration/rspec_spec.rb +22 -25
- data/spec/integration/templating_spec.rb +7 -6
- data/spec/pacto/dummy_server.rb +4 -0
- data/spec/pacto/{server → dummy_server}/dummy.rb +7 -6
- data/spec/pacto/dummy_server/jruby_workaround_helper.rb +23 -0
- data/spec/pacto/{server → dummy_server}/playback_servlet.rb +3 -2
- data/spec/spec_helper.rb +16 -7
- data/spec/unit/actors/from_examples_spec.rb +70 -0
- data/spec/unit/actors/json_generator_spec.rb +105 -0
- data/spec/unit/pacto/actor_spec.rb +23 -0
- data/spec/unit/pacto/configuration_spec.rb +7 -6
- data/spec/unit/pacto/consumer/faraday_driver_spec.rb +40 -0
- data/spec/unit/pacto/contract_builder_spec.rb +89 -0
- data/spec/unit/pacto/contract_factory_spec.rb +62 -11
- data/spec/unit/pacto/contract_files_spec.rb +1 -0
- data/spec/unit/pacto/contract_set_spec.rb +36 -0
- data/spec/unit/pacto/contract_spec.rb +51 -39
- data/spec/unit/pacto/cops/body_cop_spec.rb +107 -0
- data/spec/unit/pacto/{validators/response_header_validator_spec.rb → cops/response_header_cop_spec.rb} +30 -19
- data/spec/unit/pacto/cops/response_status_cop_spec.rb +26 -0
- data/spec/unit/pacto/cops_spec.rb +75 -0
- data/spec/unit/pacto/core/configuration_spec.rb +6 -5
- data/spec/unit/pacto/core/contract_registry_spec.rb +16 -83
- data/spec/unit/pacto/core/http_middleware_spec.rb +36 -0
- data/spec/unit/pacto/core/investigation_spec.rb +62 -0
- data/spec/unit/pacto/core/modes_spec.rb +5 -4
- data/spec/unit/pacto/erb_processor_spec.rb +3 -2
- data/spec/unit/pacto/extensions_spec.rb +10 -20
- data/spec/unit/pacto/generator/filters_spec.rb +11 -10
- data/spec/unit/pacto/generator/native_contract_generator_spec.rb +171 -0
- data/spec/unit/{hooks → pacto/hooks}/erb_hook_spec.rb +18 -11
- data/spec/unit/pacto/investigation_registry_spec.rb +77 -0
- data/spec/unit/pacto/logger_spec.rb +6 -5
- data/spec/unit/pacto/meta_schema_spec.rb +5 -4
- data/spec/unit/pacto/native_contract_factory_spec.rb +26 -0
- data/spec/unit/pacto/pacto_spec.rb +13 -28
- data/spec/unit/pacto/request_clause_spec.rb +16 -51
- data/spec/unit/pacto/request_pattern_spec.rb +6 -5
- data/spec/unit/pacto/response_clause_spec.rb +6 -19
- data/spec/unit/pacto/server/playback_servlet_spec.rb +21 -18
- data/spec/unit/pacto/stubs/observers/stenographer_spec.rb +33 -0
- data/spec/unit/pacto/stubs/uri_pattern_spec.rb +39 -11
- data/spec/unit/pacto/stubs/webmock_adapter_spec.rb +67 -117
- data/spec/unit/pacto/swagger_contract_factory_spec.rb +56 -0
- data/spec/unit/pacto/uri_spec.rb +1 -0
- data/tasks/release.rake +57 -0
- metadata +247 -76
- data/.rubocop-todo.yml +0 -24
- data/.ruby-gemset +0 -1
- data/.ruby-version +0 -1
- data/CHANGELOG +0 -12
- data/features/validate/body_only.feature +0 -85
- data/lib/pacto/contract_list.rb +0 -17
- data/lib/pacto/contract_validator.rb +0 -29
- data/lib/pacto/core/validation_registry.rb +0 -40
- data/lib/pacto/stubs/webmock_helper.rb +0 -69
- data/lib/pacto/validation.rb +0 -54
- data/lib/pacto/validators/body_validator.rb +0 -49
- data/lib/pacto/validators/request_body_validator.rb +0 -26
- data/lib/pacto/validators/response_body_validator.rb +0 -26
- data/lib/pacto/validators/response_status_validator.rb +0 -24
- data/spec/pacto/server.rb +0 -2
- data/spec/unit/pacto/contract_list_spec.rb +0 -35
- data/spec/unit/pacto/contract_validator_spec.rb +0 -85
- data/spec/unit/pacto/core/validation_registry_spec.rb +0 -76
- data/spec/unit/pacto/core/validation_spec.rb +0 -60
- data/spec/unit/pacto/generator_spec.rb +0 -132
- data/spec/unit/pacto/stubs/webmock_helper_spec.rb +0 -20
- data/spec/unit/pacto/validators/body_validator_spec.rb +0 -118
- data/spec/unit/pacto/validators/response_status_validator_spec.rb +0 -20
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: pacto
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.4.0.rc1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- ThoughtWorks & Abril
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-
|
11
|
+
date: 2014-11-18 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: webmock
|
@@ -16,14 +16,40 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: '1.
|
19
|
+
version: '1.18'
|
20
|
+
- - "<"
|
21
|
+
- !ruby/object:Gem::Version
|
22
|
+
version: 1.20.3
|
23
|
+
type: :runtime
|
24
|
+
prerelease: false
|
25
|
+
version_requirements: !ruby/object:Gem::Requirement
|
26
|
+
requirements:
|
27
|
+
- - "~>"
|
28
|
+
- !ruby/object:Gem::Version
|
29
|
+
version: '1.18'
|
30
|
+
- - "<"
|
31
|
+
- !ruby/object:Gem::Version
|
32
|
+
version: 1.20.3
|
33
|
+
- !ruby/object:Gem::Dependency
|
34
|
+
name: swagger-core
|
35
|
+
requirement: !ruby/object:Gem::Requirement
|
36
|
+
requirements:
|
37
|
+
- - "~>"
|
38
|
+
- !ruby/object:Gem::Version
|
39
|
+
version: '0.2'
|
40
|
+
- - ">="
|
41
|
+
- !ruby/object:Gem::Version
|
42
|
+
version: 0.2.1
|
20
43
|
type: :runtime
|
21
44
|
prerelease: false
|
22
45
|
version_requirements: !ruby/object:Gem::Requirement
|
23
46
|
requirements:
|
24
47
|
- - "~>"
|
25
48
|
- !ruby/object:Gem::Version
|
26
|
-
version: '
|
49
|
+
version: '0.2'
|
50
|
+
- - ">="
|
51
|
+
- !ruby/object:Gem::Version
|
52
|
+
version: 0.2.1
|
27
53
|
- !ruby/object:Gem::Dependency
|
28
54
|
name: middleware
|
29
55
|
requirement: !ruby/object:Gem::Requirement
|
@@ -87,19 +113,19 @@ dependencies:
|
|
87
113
|
- !ruby/object:Gem::Version
|
88
114
|
version: 0.0.5
|
89
115
|
- !ruby/object:Gem::Dependency
|
90
|
-
name:
|
116
|
+
name: hashie
|
91
117
|
requirement: !ruby/object:Gem::Requirement
|
92
118
|
requirements:
|
93
119
|
- - "~>"
|
94
120
|
- !ruby/object:Gem::Version
|
95
|
-
version: '0
|
121
|
+
version: '3.0'
|
96
122
|
type: :runtime
|
97
123
|
prerelease: false
|
98
124
|
version_requirements: !ruby/object:Gem::Requirement
|
99
125
|
requirements:
|
100
126
|
- - "~>"
|
101
127
|
- !ruby/object:Gem::Version
|
102
|
-
version: '0
|
128
|
+
version: '3.0'
|
103
129
|
- !ruby/object:Gem::Dependency
|
104
130
|
name: faraday
|
105
131
|
requirement: !ruby/object:Gem::Requirement
|
@@ -149,19 +175,39 @@ dependencies:
|
|
149
175
|
- !ruby/object:Gem::Version
|
150
176
|
version: 0.0.7
|
151
177
|
- !ruby/object:Gem::Dependency
|
152
|
-
name:
|
178
|
+
name: thor
|
153
179
|
requirement: !ruby/object:Gem::Requirement
|
154
180
|
requirements:
|
155
181
|
- - "~>"
|
156
182
|
- !ruby/object:Gem::Version
|
157
|
-
version: '
|
183
|
+
version: '0.19'
|
158
184
|
type: :runtime
|
159
185
|
prerelease: false
|
160
186
|
version_requirements: !ruby/object:Gem::Requirement
|
161
187
|
requirements:
|
162
188
|
- - "~>"
|
163
189
|
- !ruby/object:Gem::Version
|
164
|
-
version: '
|
190
|
+
version: '0.19'
|
191
|
+
- !ruby/object:Gem::Dependency
|
192
|
+
name: polytrix
|
193
|
+
requirement: !ruby/object:Gem::Requirement
|
194
|
+
requirements:
|
195
|
+
- - "~>"
|
196
|
+
- !ruby/object:Gem::Version
|
197
|
+
version: '0.1'
|
198
|
+
- - ">="
|
199
|
+
- !ruby/object:Gem::Version
|
200
|
+
version: 0.1.4
|
201
|
+
type: :development
|
202
|
+
prerelease: false
|
203
|
+
version_requirements: !ruby/object:Gem::Requirement
|
204
|
+
requirements:
|
205
|
+
- - "~>"
|
206
|
+
- !ruby/object:Gem::Version
|
207
|
+
version: '0.1'
|
208
|
+
- - ">="
|
209
|
+
- !ruby/object:Gem::Version
|
210
|
+
version: 0.1.4
|
165
211
|
- !ruby/object:Gem::Dependency
|
166
212
|
name: coveralls
|
167
213
|
requirement: !ruby/object:Gem::Requirement
|
@@ -176,6 +222,20 @@ dependencies:
|
|
176
222
|
- - "~>"
|
177
223
|
- !ruby/object:Gem::Version
|
178
224
|
version: '0'
|
225
|
+
- !ruby/object:Gem::Dependency
|
226
|
+
name: fabrication
|
227
|
+
requirement: !ruby/object:Gem::Requirement
|
228
|
+
requirements:
|
229
|
+
- - "~>"
|
230
|
+
- !ruby/object:Gem::Version
|
231
|
+
version: '2.11'
|
232
|
+
type: :development
|
233
|
+
prerelease: false
|
234
|
+
version_requirements: !ruby/object:Gem::Requirement
|
235
|
+
requirements:
|
236
|
+
- - "~>"
|
237
|
+
- !ruby/object:Gem::Version
|
238
|
+
version: '2.11'
|
179
239
|
- !ruby/object:Gem::Dependency
|
180
240
|
name: rake
|
181
241
|
requirement: !ruby/object:Gem::Requirement
|
@@ -210,42 +270,42 @@ dependencies:
|
|
210
270
|
requirements:
|
211
271
|
- - "~>"
|
212
272
|
- !ruby/object:Gem::Version
|
213
|
-
version: '
|
273
|
+
version: '3.0'
|
214
274
|
type: :development
|
215
275
|
prerelease: false
|
216
276
|
version_requirements: !ruby/object:Gem::Requirement
|
217
277
|
requirements:
|
218
278
|
- - "~>"
|
219
279
|
- !ruby/object:Gem::Version
|
220
|
-
version: '
|
280
|
+
version: '3.0'
|
221
281
|
- !ruby/object:Gem::Dependency
|
222
|
-
name:
|
282
|
+
name: aruba
|
223
283
|
requirement: !ruby/object:Gem::Requirement
|
224
284
|
requirements:
|
225
285
|
- - "~>"
|
226
286
|
- !ruby/object:Gem::Version
|
227
|
-
version: '
|
287
|
+
version: '0'
|
228
288
|
type: :development
|
229
289
|
prerelease: false
|
230
290
|
version_requirements: !ruby/object:Gem::Requirement
|
231
291
|
requirements:
|
232
292
|
- - "~>"
|
233
293
|
- !ruby/object:Gem::Version
|
234
|
-
version: '
|
294
|
+
version: '0'
|
235
295
|
- !ruby/object:Gem::Dependency
|
236
|
-
name:
|
296
|
+
name: json_spec
|
237
297
|
requirement: !ruby/object:Gem::Requirement
|
238
298
|
requirements:
|
239
299
|
- - "~>"
|
240
300
|
- !ruby/object:Gem::Version
|
241
|
-
version: '0'
|
301
|
+
version: '1.0'
|
242
302
|
type: :development
|
243
303
|
prerelease: false
|
244
304
|
version_requirements: !ruby/object:Gem::Requirement
|
245
305
|
requirements:
|
246
306
|
- - "~>"
|
247
307
|
- !ruby/object:Gem::Version
|
248
|
-
version: '0'
|
308
|
+
version: '1.0'
|
249
309
|
- !ruby/object:Gem::Dependency
|
250
310
|
name: guard-rspec
|
251
311
|
requirement: !ruby/object:Gem::Requirement
|
@@ -266,14 +326,34 @@ dependencies:
|
|
266
326
|
requirements:
|
267
327
|
- - "~>"
|
268
328
|
- !ruby/object:Gem::Version
|
269
|
-
version: '0.
|
329
|
+
version: '0.23'
|
330
|
+
- - "<"
|
331
|
+
- !ruby/object:Gem::Version
|
332
|
+
version: 0.27.0
|
333
|
+
type: :development
|
334
|
+
prerelease: false
|
335
|
+
version_requirements: !ruby/object:Gem::Requirement
|
336
|
+
requirements:
|
337
|
+
- - "~>"
|
338
|
+
- !ruby/object:Gem::Version
|
339
|
+
version: '0.23'
|
340
|
+
- - "<"
|
341
|
+
- !ruby/object:Gem::Version
|
342
|
+
version: 0.27.0
|
343
|
+
- !ruby/object:Gem::Dependency
|
344
|
+
name: rubocop-rspec
|
345
|
+
requirement: !ruby/object:Gem::Requirement
|
346
|
+
requirements:
|
347
|
+
- - "~>"
|
348
|
+
- !ruby/object:Gem::Version
|
349
|
+
version: 1.0.rc3
|
270
350
|
type: :development
|
271
351
|
prerelease: false
|
272
352
|
version_requirements: !ruby/object:Gem::Requirement
|
273
353
|
requirements:
|
274
354
|
- - "~>"
|
275
355
|
- !ruby/object:Gem::Version
|
276
|
-
version:
|
356
|
+
version: 1.0.rc3
|
277
357
|
- !ruby/object:Gem::Dependency
|
278
358
|
name: guard-rubocop
|
279
359
|
requirement: !ruby/object:Gem::Requirement
|
@@ -336,25 +416,36 @@ description: Pacto is a judge that arbitrates contract disputes between a servic
|
|
336
416
|
Contracts or Documentation-Driven Contracts.
|
337
417
|
email:
|
338
418
|
- pacto-gem@googlegroups.com
|
339
|
-
executables:
|
419
|
+
executables:
|
420
|
+
- pacto
|
340
421
|
extensions: []
|
341
422
|
extra_rdoc_files: []
|
342
423
|
files:
|
343
424
|
- ".gitignore"
|
344
425
|
- ".rspec"
|
345
|
-
- ".rubocop-todo.yml"
|
346
426
|
- ".rubocop.yml"
|
347
|
-
- ".ruby-gemset"
|
348
|
-
- ".ruby-version"
|
349
427
|
- ".travis.yml"
|
350
|
-
- CHANGELOG
|
351
428
|
- CONTRIBUTING.md
|
352
429
|
- Gemfile
|
353
430
|
- Guardfile
|
354
431
|
- LICENSE.txt
|
432
|
+
- Procfile
|
355
433
|
- README.md
|
356
434
|
- Rakefile
|
357
435
|
- TODO.md
|
436
|
+
- bin/pacto
|
437
|
+
- changelog.md
|
438
|
+
- docs/configuration.md
|
439
|
+
- docs/consumer.md
|
440
|
+
- docs/cops.md
|
441
|
+
- docs/forensics.md
|
442
|
+
- docs/generation.md
|
443
|
+
- docs/rake_tasks.md
|
444
|
+
- docs/rspec.md
|
445
|
+
- docs/samples.md
|
446
|
+
- docs/server.md
|
447
|
+
- docs/server_cli.md
|
448
|
+
- docs/stenographer.md
|
358
449
|
- features/configuration/strict_matchers.feature
|
359
450
|
- features/evolve/README.md
|
360
451
|
- features/evolve/existing_services.feature
|
@@ -365,91 +456,157 @@ files:
|
|
365
456
|
- features/stub/templates.feature
|
366
457
|
- features/support/env.rb
|
367
458
|
- features/validate/README.md
|
368
|
-
- features/validate/body_only.feature
|
369
459
|
- features/validate/meta_validation.feature
|
370
460
|
- features/validate/validation.feature
|
371
461
|
- lib/pacto.rb
|
462
|
+
- lib/pacto/actor.rb
|
463
|
+
- lib/pacto/actors/from_examples.rb
|
464
|
+
- lib/pacto/actors/json_generator.rb
|
465
|
+
- lib/pacto/cli.rb
|
466
|
+
- lib/pacto/cli/helpers.rb
|
467
|
+
- lib/pacto/consumer.rb
|
468
|
+
- lib/pacto/consumer/faraday_driver.rb
|
372
469
|
- lib/pacto/contract.rb
|
470
|
+
- lib/pacto/contract_builder.rb
|
373
471
|
- lib/pacto/contract_factory.rb
|
374
472
|
- lib/pacto/contract_files.rb
|
375
|
-
- lib/pacto/
|
376
|
-
- lib/pacto/
|
473
|
+
- lib/pacto/contract_set.rb
|
474
|
+
- lib/pacto/cops.rb
|
475
|
+
- lib/pacto/cops/body_cop.rb
|
476
|
+
- lib/pacto/cops/request_body_cop.rb
|
477
|
+
- lib/pacto/cops/response_body_cop.rb
|
478
|
+
- lib/pacto/cops/response_header_cop.rb
|
479
|
+
- lib/pacto/cops/response_status_cop.rb
|
377
480
|
- lib/pacto/core/configuration.rb
|
378
481
|
- lib/pacto/core/contract_registry.rb
|
379
482
|
- lib/pacto/core/hook.rb
|
483
|
+
- lib/pacto/core/http_middleware.rb
|
484
|
+
- lib/pacto/core/investigation_registry.rb
|
380
485
|
- lib/pacto/core/modes.rb
|
381
|
-
- lib/pacto/core/
|
486
|
+
- lib/pacto/core/pacto_request.rb
|
487
|
+
- lib/pacto/core/pacto_response.rb
|
488
|
+
- lib/pacto/dash.rb
|
382
489
|
- lib/pacto/erb_processor.rb
|
383
490
|
- lib/pacto/exceptions/invalid_contract.rb
|
384
491
|
- lib/pacto/extensions.rb
|
492
|
+
- lib/pacto/forensics/investigation_filter.rb
|
493
|
+
- lib/pacto/forensics/investigation_matcher.rb
|
385
494
|
- lib/pacto/generator.rb
|
386
495
|
- lib/pacto/generator/filters.rb
|
496
|
+
- lib/pacto/generator/hint.rb
|
497
|
+
- lib/pacto/generator/native_contract_generator.rb
|
387
498
|
- lib/pacto/hooks/erb_hook.rb
|
499
|
+
- lib/pacto/investigation.rb
|
388
500
|
- lib/pacto/logger.rb
|
389
501
|
- lib/pacto/meta_schema.rb
|
502
|
+
- lib/pacto/native_contract_factory.rb
|
503
|
+
- lib/pacto/observers/stenographer.rb
|
504
|
+
- lib/pacto/provider.rb
|
390
505
|
- lib/pacto/rake_task.rb
|
391
506
|
- lib/pacto/request_clause.rb
|
392
507
|
- lib/pacto/request_pattern.rb
|
508
|
+
- lib/pacto/resettable.rb
|
393
509
|
- lib/pacto/response_clause.rb
|
394
510
|
- lib/pacto/rspec.rb
|
511
|
+
- lib/pacto/server.rb
|
395
512
|
- lib/pacto/stubs/uri_pattern.rb
|
396
513
|
- lib/pacto/stubs/webmock_adapter.rb
|
397
|
-
- lib/pacto/
|
514
|
+
- lib/pacto/swagger_contract_factory.rb
|
515
|
+
- lib/pacto/test_helper.rb
|
398
516
|
- lib/pacto/ui.rb
|
399
517
|
- lib/pacto/uri.rb
|
400
|
-
- lib/pacto/validation.rb
|
401
|
-
- lib/pacto/validators/body_validator.rb
|
402
|
-
- lib/pacto/validators/request_body_validator.rb
|
403
|
-
- lib/pacto/validators/response_body_validator.rb
|
404
|
-
- lib/pacto/validators/response_header_validator.rb
|
405
|
-
- lib/pacto/validators/response_status_validator.rb
|
406
518
|
- lib/pacto/version.rb
|
519
|
+
- pacto-server.gemspec
|
407
520
|
- pacto.gemspec
|
408
521
|
- resources/contract_schema.json
|
409
522
|
- resources/draft-03.json
|
523
|
+
- resources/draft-04.json
|
524
|
+
- sample_apis/album/cover_api.rb
|
525
|
+
- sample_apis/config.ru
|
526
|
+
- sample_apis/echo_api.rb
|
527
|
+
- sample_apis/files_api.rb
|
528
|
+
- sample_apis/hello_api.rb
|
529
|
+
- sample_apis/ping_api.rb
|
530
|
+
- sample_apis/reverse_api.rb
|
531
|
+
- samples/README.md
|
532
|
+
- samples/Rakefile
|
533
|
+
- samples/configuration.rb
|
534
|
+
- samples/consumer.rb
|
535
|
+
- samples/contracts/README.md
|
536
|
+
- samples/contracts/contract.js
|
537
|
+
- samples/contracts/get_album_cover.json
|
538
|
+
- samples/contracts/localhost/api/echo.json
|
539
|
+
- samples/contracts/localhost/api/ping.json
|
540
|
+
- samples/cops.rb
|
541
|
+
- samples/forensics.rb
|
542
|
+
- samples/generation.rb
|
543
|
+
- samples/rake_tasks.sh
|
544
|
+
- samples/rspec.rb
|
545
|
+
- samples/samples.rb
|
546
|
+
- samples/scripts/bootstrap
|
547
|
+
- samples/scripts/wrapper
|
548
|
+
- samples/server.rb
|
549
|
+
- samples/server_cli.sh
|
550
|
+
- samples/stenographer.rb
|
410
551
|
- spec/coveralls_helper.rb
|
411
|
-
- spec/
|
412
|
-
- spec/
|
413
|
-
- spec/
|
552
|
+
- spec/fabricators/contract_fabricator.rb
|
553
|
+
- spec/fabricators/http_fabricator.rb
|
554
|
+
- spec/fabricators/webmock_fabricator.rb
|
555
|
+
- spec/fixtures/contracts/contract.json
|
556
|
+
- spec/fixtures/contracts/contract_with_examples.json
|
557
|
+
- spec/fixtures/contracts/simple_contract.json
|
558
|
+
- spec/fixtures/contracts/strict_contract.json
|
559
|
+
- spec/fixtures/contracts/templating_contract.json
|
560
|
+
- spec/fixtures/deprecated_contracts/deprecated_contract.json
|
561
|
+
- spec/fixtures/swagger/petstore.yaml
|
414
562
|
- spec/integration/e2e_spec.rb
|
563
|
+
- spec/integration/forensics/integration_matcher_spec.rb
|
415
564
|
- spec/integration/rspec_spec.rb
|
416
565
|
- spec/integration/templating_spec.rb
|
417
|
-
- spec/pacto/
|
418
|
-
- spec/pacto/
|
419
|
-
- spec/pacto/
|
566
|
+
- spec/pacto/dummy_server.rb
|
567
|
+
- spec/pacto/dummy_server/dummy.rb
|
568
|
+
- spec/pacto/dummy_server/jruby_workaround_helper.rb
|
569
|
+
- spec/pacto/dummy_server/playback_servlet.rb
|
420
570
|
- spec/spec_helper.rb
|
421
|
-
- spec/unit/
|
422
|
-
- spec/unit/
|
423
|
-
- spec/unit/
|
571
|
+
- spec/unit/actors/from_examples_spec.rb
|
572
|
+
- spec/unit/actors/json_generator_spec.rb
|
573
|
+
- spec/unit/pacto/actor_spec.rb
|
424
574
|
- spec/unit/pacto/configuration_spec.rb
|
575
|
+
- spec/unit/pacto/consumer/faraday_driver_spec.rb
|
576
|
+
- spec/unit/pacto/contract_builder_spec.rb
|
425
577
|
- spec/unit/pacto/contract_factory_spec.rb
|
426
578
|
- spec/unit/pacto/contract_files_spec.rb
|
427
|
-
- spec/unit/pacto/
|
579
|
+
- spec/unit/pacto/contract_set_spec.rb
|
428
580
|
- spec/unit/pacto/contract_spec.rb
|
429
|
-
- spec/unit/pacto/
|
581
|
+
- spec/unit/pacto/cops/body_cop_spec.rb
|
582
|
+
- spec/unit/pacto/cops/response_header_cop_spec.rb
|
583
|
+
- spec/unit/pacto/cops/response_status_cop_spec.rb
|
584
|
+
- spec/unit/pacto/cops_spec.rb
|
430
585
|
- spec/unit/pacto/core/configuration_spec.rb
|
431
586
|
- spec/unit/pacto/core/contract_registry_spec.rb
|
587
|
+
- spec/unit/pacto/core/http_middleware_spec.rb
|
588
|
+
- spec/unit/pacto/core/investigation_spec.rb
|
432
589
|
- spec/unit/pacto/core/modes_spec.rb
|
433
|
-
- spec/unit/pacto/core/validation_registry_spec.rb
|
434
|
-
- spec/unit/pacto/core/validation_spec.rb
|
435
590
|
- spec/unit/pacto/erb_processor_spec.rb
|
436
591
|
- spec/unit/pacto/extensions_spec.rb
|
437
592
|
- spec/unit/pacto/generator/filters_spec.rb
|
438
|
-
- spec/unit/pacto/
|
593
|
+
- spec/unit/pacto/generator/native_contract_generator_spec.rb
|
594
|
+
- spec/unit/pacto/hooks/erb_hook_spec.rb
|
595
|
+
- spec/unit/pacto/investigation_registry_spec.rb
|
439
596
|
- spec/unit/pacto/logger_spec.rb
|
440
597
|
- spec/unit/pacto/meta_schema_spec.rb
|
598
|
+
- spec/unit/pacto/native_contract_factory_spec.rb
|
441
599
|
- spec/unit/pacto/pacto_spec.rb
|
442
600
|
- spec/unit/pacto/request_clause_spec.rb
|
443
601
|
- spec/unit/pacto/request_pattern_spec.rb
|
444
602
|
- spec/unit/pacto/response_clause_spec.rb
|
445
603
|
- spec/unit/pacto/server/playback_servlet_spec.rb
|
604
|
+
- spec/unit/pacto/stubs/observers/stenographer_spec.rb
|
446
605
|
- spec/unit/pacto/stubs/uri_pattern_spec.rb
|
447
606
|
- spec/unit/pacto/stubs/webmock_adapter_spec.rb
|
448
|
-
- spec/unit/pacto/
|
607
|
+
- spec/unit/pacto/swagger_contract_factory_spec.rb
|
449
608
|
- spec/unit/pacto/uri_spec.rb
|
450
|
-
-
|
451
|
-
- spec/unit/pacto/validators/response_header_validator_spec.rb
|
452
|
-
- spec/unit/pacto/validators/response_status_validator_spec.rb
|
609
|
+
- tasks/release.rake
|
453
610
|
homepage: http://thoughtworks.github.io/pacto/
|
454
611
|
licenses:
|
455
612
|
- MIT
|
@@ -465,12 +622,12 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
465
622
|
version: '0'
|
466
623
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
467
624
|
requirements:
|
468
|
-
- - "
|
625
|
+
- - ">"
|
469
626
|
- !ruby/object:Gem::Version
|
470
|
-
version:
|
627
|
+
version: 1.3.1
|
471
628
|
requirements: []
|
472
629
|
rubyforge_project:
|
473
|
-
rubygems_version: 2.2
|
630
|
+
rubygems_version: 2.4.2
|
474
631
|
signing_key:
|
475
632
|
specification_version: 4
|
476
633
|
summary: Integration Contract Testing framework
|
@@ -485,49 +642,63 @@ test_files:
|
|
485
642
|
- features/stub/templates.feature
|
486
643
|
- features/support/env.rb
|
487
644
|
- features/validate/README.md
|
488
|
-
- features/validate/body_only.feature
|
489
645
|
- features/validate/meta_validation.feature
|
490
646
|
- features/validate/validation.feature
|
491
647
|
- spec/coveralls_helper.rb
|
492
|
-
- spec/
|
493
|
-
- spec/
|
494
|
-
- spec/
|
648
|
+
- spec/fabricators/contract_fabricator.rb
|
649
|
+
- spec/fabricators/http_fabricator.rb
|
650
|
+
- spec/fabricators/webmock_fabricator.rb
|
651
|
+
- spec/fixtures/contracts/contract.json
|
652
|
+
- spec/fixtures/contracts/contract_with_examples.json
|
653
|
+
- spec/fixtures/contracts/simple_contract.json
|
654
|
+
- spec/fixtures/contracts/strict_contract.json
|
655
|
+
- spec/fixtures/contracts/templating_contract.json
|
656
|
+
- spec/fixtures/deprecated_contracts/deprecated_contract.json
|
657
|
+
- spec/fixtures/swagger/petstore.yaml
|
495
658
|
- spec/integration/e2e_spec.rb
|
659
|
+
- spec/integration/forensics/integration_matcher_spec.rb
|
496
660
|
- spec/integration/rspec_spec.rb
|
497
661
|
- spec/integration/templating_spec.rb
|
498
|
-
- spec/pacto/
|
499
|
-
- spec/pacto/
|
500
|
-
- spec/pacto/
|
662
|
+
- spec/pacto/dummy_server.rb
|
663
|
+
- spec/pacto/dummy_server/dummy.rb
|
664
|
+
- spec/pacto/dummy_server/jruby_workaround_helper.rb
|
665
|
+
- spec/pacto/dummy_server/playback_servlet.rb
|
501
666
|
- spec/spec_helper.rb
|
502
|
-
- spec/unit/
|
503
|
-
- spec/unit/
|
504
|
-
- spec/unit/
|
667
|
+
- spec/unit/actors/from_examples_spec.rb
|
668
|
+
- spec/unit/actors/json_generator_spec.rb
|
669
|
+
- spec/unit/pacto/actor_spec.rb
|
505
670
|
- spec/unit/pacto/configuration_spec.rb
|
671
|
+
- spec/unit/pacto/consumer/faraday_driver_spec.rb
|
672
|
+
- spec/unit/pacto/contract_builder_spec.rb
|
506
673
|
- spec/unit/pacto/contract_factory_spec.rb
|
507
674
|
- spec/unit/pacto/contract_files_spec.rb
|
508
|
-
- spec/unit/pacto/
|
675
|
+
- spec/unit/pacto/contract_set_spec.rb
|
509
676
|
- spec/unit/pacto/contract_spec.rb
|
510
|
-
- spec/unit/pacto/
|
677
|
+
- spec/unit/pacto/cops/body_cop_spec.rb
|
678
|
+
- spec/unit/pacto/cops/response_header_cop_spec.rb
|
679
|
+
- spec/unit/pacto/cops/response_status_cop_spec.rb
|
680
|
+
- spec/unit/pacto/cops_spec.rb
|
511
681
|
- spec/unit/pacto/core/configuration_spec.rb
|
512
682
|
- spec/unit/pacto/core/contract_registry_spec.rb
|
683
|
+
- spec/unit/pacto/core/http_middleware_spec.rb
|
684
|
+
- spec/unit/pacto/core/investigation_spec.rb
|
513
685
|
- spec/unit/pacto/core/modes_spec.rb
|
514
|
-
- spec/unit/pacto/core/validation_registry_spec.rb
|
515
|
-
- spec/unit/pacto/core/validation_spec.rb
|
516
686
|
- spec/unit/pacto/erb_processor_spec.rb
|
517
687
|
- spec/unit/pacto/extensions_spec.rb
|
518
688
|
- spec/unit/pacto/generator/filters_spec.rb
|
519
|
-
- spec/unit/pacto/
|
689
|
+
- spec/unit/pacto/generator/native_contract_generator_spec.rb
|
690
|
+
- spec/unit/pacto/hooks/erb_hook_spec.rb
|
691
|
+
- spec/unit/pacto/investigation_registry_spec.rb
|
520
692
|
- spec/unit/pacto/logger_spec.rb
|
521
693
|
- spec/unit/pacto/meta_schema_spec.rb
|
694
|
+
- spec/unit/pacto/native_contract_factory_spec.rb
|
522
695
|
- spec/unit/pacto/pacto_spec.rb
|
523
696
|
- spec/unit/pacto/request_clause_spec.rb
|
524
697
|
- spec/unit/pacto/request_pattern_spec.rb
|
525
698
|
- spec/unit/pacto/response_clause_spec.rb
|
526
699
|
- spec/unit/pacto/server/playback_servlet_spec.rb
|
700
|
+
- spec/unit/pacto/stubs/observers/stenographer_spec.rb
|
527
701
|
- spec/unit/pacto/stubs/uri_pattern_spec.rb
|
528
702
|
- spec/unit/pacto/stubs/webmock_adapter_spec.rb
|
529
|
-
- spec/unit/pacto/
|
703
|
+
- spec/unit/pacto/swagger_contract_factory_spec.rb
|
530
704
|
- spec/unit/pacto/uri_spec.rb
|
531
|
-
- spec/unit/pacto/validators/body_validator_spec.rb
|
532
|
-
- spec/unit/pacto/validators/response_header_validator_spec.rb
|
533
|
-
- spec/unit/pacto/validators/response_status_validator_spec.rb
|