Method: Beaker::LoggerJunit.finish

Defined in:
lib/beaker/logger_junit.rb

.finish(doc, xml_file) ⇒ Object

writes out xml content for a doc

Parameters:

  • doc (REXML::Document)

    doc containing content to write

  • xml_file (String)

    Path to the xml file to write

Returns:

  • nil



42
43
44
45
46
# File 'lib/beaker/logger_junit.rb', line 42

def self.finish(doc, xml_file)
  # junit/name.xml will be created in a directory relative to the CWD

  File.open(xml_file, 'w') { |f| doc.write(f, 2) }
end