Module: JunitReportGenerator::Containable
- Defined in:
- lib/junit_report_generator/containable.rb
Instance Attribute Summary collapse
-
#sub_elements ⇒ Object
readonly
Returns the value of attribute sub_elements.
Instance Method Summary collapse
Instance Attribute Details
#sub_elements ⇒ Object (readonly)
Returns the value of attribute sub_elements.
3 4 5 |
# File 'lib/junit_report_generator/containable.rb', line 3 def sub_elements @sub_elements end |
Instance Method Details
#add(*sub_elements) ⇒ Object
10 11 12 13 14 15 |
# File 'lib/junit_report_generator/containable.rb', line 10 def add(*sub_elements) @sub_elements ||= [] @sub_elements.concat(sub_elements) @blk.call(sub_elements) if defined?(@blk) && @blk self end |