Class: PactBroker::Api::Renderers::HtmlPactRenderer
- Inherits:
-
Object
- Object
- PactBroker::Api::Renderers::HtmlPactRenderer
- Includes:
- Logging
- Defined in:
- lib/pact_broker/api/renderers/html_pact_renderer.rb
Defined Under Namespace
Classes: NotAPactError
Class Method Summary collapse
Instance Method Summary collapse
- #call ⇒ Object
-
#initialize(pact, options = {}) ⇒ HtmlPactRenderer
constructor
A new instance of HtmlPactRenderer.
Methods included from Logging
Constructor Details
#initialize(pact, options = {}) ⇒ HtmlPactRenderer
Returns a new instance of HtmlPactRenderer.
21 22 23 24 25 |
# File 'lib/pact_broker/api/renderers/html_pact_renderer.rb', line 21 def initialize pact, = {} @json_content = pact.json_content @pact = pact @options = end |
Class Method Details
.call(pact, options = {}) ⇒ Object
17 18 19 |
# File 'lib/pact_broker/api/renderers/html_pact_renderer.rb', line 17 def self.call pact, = {} new(pact, ).call end |
Instance Method Details
#call ⇒ Object
27 28 29 30 31 32 33 34 |
# File 'lib/pact_broker/api/renderers/html_pact_renderer.rb', line 27 def call "<html> <head>#{head}</head> <body> #{}#{html} </body> </html>" end |