Class: PullReview::Coverage::ClientApi
- Inherits:
-
Object
- Object
- PullReview::Coverage::ClientApi
- Defined in:
- lib/pullreview/coverage/client_api.rb
Overview
Remote api based implementation for production intent
Instance Attribute Summary collapse
-
#config ⇒ Object
readonly
Returns the value of attribute config.
Instance Method Summary collapse
-
#initialize(config) ⇒ ClientApi
constructor
A new instance of ClientApi.
-
#publish(payload) ⇒ Object
post json payload to pullreview host.
Constructor Details
Instance Attribute Details
#config ⇒ Object (readonly)
Returns the value of attribute config.
27 28 29 |
# File 'lib/pullreview/coverage/client_api.rb', line 27 def config @config end |
Instance Method Details
#publish(payload) ⇒ Object
post json payload to pullreview host.
34 35 36 37 38 39 |
# File 'lib/pullreview/coverage/client_api.rb', line 34 def publish(payload) allow_pullreview_webmock allow_pullreview_vcr response = post(payload) "#{response.code} : #{response.body}" end |