Class: Spoom::Coverage::Cards::Card

Inherits:
Template
  • Object
show all
Extended by:
T::Sig
Defined in:
lib/spoom/coverage/report.rb

Direct Known Subclasses

Erb, Map, Snapshot, Timeline

Constant Summary collapse

TEMPLATE =
T.let("#{Spoom::SPOOM_PATH}/templates/card.erb", String)

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Template

#erb, #get_binding, #html

Constructor Details

#initialize(template: TEMPLATE, title: nil, body: nil) ⇒ Card

Returns a new instance of Card.



98
99
100
101
102
# File 'lib/spoom/coverage/report.rb', line 98

def initialize(template: TEMPLATE, title: nil, body: nil)
  super(template: template)
  @title = title
  @body = body
end

Instance Attribute Details

#bodyObject (readonly)

Returns the value of attribute body.



95
96
97
# File 'lib/spoom/coverage/report.rb', line 95

def body
  @body
end

#titleObject (readonly)

Returns the value of attribute title.



95
96
97
# File 'lib/spoom/coverage/report.rb', line 95

def title
  @title
end