pact-message 0.1.1 → 0.1.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 40da9a34d550a04c42e1d76e5f777db9ad4ab27a
4
- data.tar.gz: '06333869e35b99613dac5fa66f65346b5f7e233c'
3
+ metadata.gz: 987ee7a93d7e2486be29a279820a93a7189e85ca
4
+ data.tar.gz: ca3015400a9b05d9af0755b80008dd722dfce8aa
5
5
  SHA512:
6
- metadata.gz: cf8980b59a3909f73d188c2a81ec86cacb72ca4eba101a72ada87e12ef3e2b8c3efbd9c706814e99f9231719226438cb0e9edecc291093231b2cf5796025f4b6
7
- data.tar.gz: 8796c96f56684c33ff357aebff1425a4569ce35a6bd607f92cf7194af91e5ed6dbef914ad6bedcaa0a832272d6bbf313a139b95a3340a2c80cdde4f6a74bebef
6
+ metadata.gz: c5e295846169414dfe580899215b7d048a4c53e1feb67f27cc606f6362a6d7f6d63f74928dee765ea83316aee1316ec30cc04a4b43e8f2395c83e44b644b514d
7
+ data.tar.gz: 93d5e5bd4964a13f75ecc9cbbd45615480d784bc09e7c56e1d00d87ac4a85864f5cf8bb2cd8852a60944ee9d80583f2517441df663857b62d9eae8a56e6504ee
data/CONTRIBUTING.md ADDED
@@ -0,0 +1 @@
1
+ # Contributing
@@ -0,0 +1,33 @@
1
+ # Developer documentation
2
+
3
+ ## Touchpoints with other gems
4
+
5
+ Because the HTTP interaction is so baked into the pact gems, the changes required to add message support to the existing code have been spread out across the various gems. I've tried to make extension points where possible in each gem so that pact-http code does not know about or rely on pact-message code at all, but in some places it was unavoidable with the current structure.
6
+
7
+ ### pact-support
8
+
9
+ To get a Pact::ConsumerContract with messages instead of http interactions (extensible design):
10
+
11
+ # lib/pact/message/consumer_contract_parser.rb
12
+ Pact::ConsumerContract.add_parser(Pact::Message::ConsumerContractParser.new)
13
+
14
+ ### pact-mock_service
15
+
16
+ To write a message pact (extensible design):
17
+
18
+ # lib/pact/message/consumer/update_pact.rb
19
+ Pact::ConsumerContractWriter.new(details, Logger.new(StringIO.new))
20
+
21
+ ### pact
22
+
23
+ To verify a message pact (yucky design, but too much work to separate it nicely right now):
24
+
25
+ # lib/pact/provider/rspec.rb
26
+
27
+ if interaction.respond_to?(:message?) && interaction.message?
28
+ describe_message Pact::Response.new(interaction.response), interaction_context
29
+ else
30
+ describe "with #{interaction.request.method_and_path}" do
31
+ describe_response Pact::Response.new(interaction.response), interaction_context
32
+ end
33
+ end
@@ -1,5 +1,5 @@
1
1
  module Pact
2
2
  module Message
3
- VERSION = "0.1.1"
3
+ VERSION = "0.1.2"
4
4
  end
5
5
  end
data/pact-message.gemspec CHANGED
@@ -25,8 +25,8 @@ Gem::Specification.new do |spec|
25
25
  spec.files = `git ls-files -z`.split("\x0").reject do |f|
26
26
  f.match(%r{^(test|spec|features)/})
27
27
  end
28
- spec.bindir = "exe"
29
- spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
28
+ spec.bindir = "bin"
29
+ spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
30
30
  spec.require_paths = ["lib"]
31
31
 
32
32
  spec.add_runtime_dependency "pact-support", "1.2.99.alpha.1"
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pact-message
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Beth Skurrie
8
8
  autorequire:
9
- bindir: exe
9
+ bindir: bin
10
10
  cert_chain: []
11
- date: 2018-03-08 00:00:00.000000000 Z
11
+ date: 2018-03-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: pact-support
@@ -111,13 +111,18 @@ dependencies:
111
111
  description:
112
112
  email:
113
113
  - beth@bethesque.com
114
- executables: []
114
+ executables:
115
+ - console
116
+ - pact-message
117
+ - setup
115
118
  extensions: []
116
119
  extra_rdoc_files: []
117
120
  files:
118
121
  - ".gitignore"
119
122
  - ".rspec"
120
123
  - ".travis.yml"
124
+ - CONTRIBUTING.md
125
+ - DEVELOPER_DOCUMENTATION.md
121
126
  - Gemfile
122
127
  - LICENSE.txt
123
128
  - QUESTIONS.md