class Test::Unit::UI::XML::TestRunner

Runs a Test::Unit::TestSuite and outputs XML.

Public Class Methods

new(suite, options={}) click to toggle source

Creates a new TestRunner for running the passed suite. :output option specifies where runner output should go to; defaults to STDOUT.

Calls superclass method Test::Unit::UI::TestRunner::new
# File test-unit-3.5.3/lib/test/unit/ui/xml/testrunner.rb, line 25
def initialize(suite, options={})
  super
  @output = @options[:output] || STDOUT
  if @options[:output_file_descriptor]
    @output = IO.new(@options[:output_file_descriptor], "w")
  end
  @already_outputted = false
  @indent = 0
  @top_level = true
  @current_test = nil
  @current_test_suite = nil
  @already_outputted = false
end