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
included, #log_error, #log_with_tag, #measure_info
Constructor Details
#initialize(pact, options = {}) ⇒ HtmlPactRenderer
Returns a new instance of HtmlPactRenderer.
22 23 24 25 26 |
# File 'lib/pact_broker/api/renderers/html_pact_renderer.rb', line 22 def initialize pact, = {} @json_content = pact.json_content @pact = pact @options = end |
Class Method Details
.call(pact, options = {}) ⇒ Object
18 19 20 |
# File 'lib/pact_broker/api/renderers/html_pact_renderer.rb', line 18 def self.call pact, = {} new(pact, ).call end |
Instance Method Details
#call ⇒ Object
28 29 30 31 32 33 34 35 |
# File 'lib/pact_broker/api/renderers/html_pact_renderer.rb', line 28 def call "<html> <head>#{head}</head> <body> #{}#{}#{html} </body> </html>" end |