Class: Casper::Report
- Inherits:
-
Object
- Object
- Casper::Report
- Defined in:
- lib/casper-client.rb
Instance Attribute Summary collapse
-
#template ⇒ Object
Returns the value of attribute template.
-
#type ⇒ Object
Returns the value of attribute type.
-
#xml ⇒ Object
Returns the value of attribute xml.
-
#xpath ⇒ Object
Returns the value of attribute xpath.
Instance Method Summary collapse
Instance Attribute Details
#template ⇒ Object
Returns the value of attribute template.
49 50 51 |
# File 'lib/casper-client.rb', line 49 def template @template end |
#type ⇒ Object
Returns the value of attribute type.
49 50 51 |
# File 'lib/casper-client.rb', line 49 def type @type end |
#xml ⇒ Object
Returns the value of attribute xml.
49 50 51 |
# File 'lib/casper-client.rb', line 49 def xml @xml end |
#xpath ⇒ Object
Returns the value of attribute xpath.
49 50 51 |
# File 'lib/casper-client.rb', line 49 def xpath @xpath end |
Instance Method Details
#to_json ⇒ Object
51 52 53 54 55 56 57 58 59 60 |
# File 'lib/casper-client.rb', line 51 def to_json {:casper => { :jrxml => Base64.encode64(self.template.read), :data => Base64.encode64((self.xml.kind_of? File) ? self.xml.read : xml), :xpath => self.xpath, :type => self.type } }.to_json end |