internetee-registry/spec/support/epp_doc.rb
2015-01-05 17:35:02 +02:00

18 lines
471 B
Ruby

class EppDoc
RSpec::Core::Formatters.register self, :start, :example_started
def initialize(output)
@output = output
end
def start(example_count)
@output.puts '# EPP REQUEST - RESPONSE EXAMPLES'
@output.puts "GENERATED AT: #{Time.now} "
@output.puts "EXAMPLE COUNT: #{example_count.count} "
@output.puts "\n---\n\n"
end
def example_started(notification)
@output.puts "### #{notification.example.full_description} \n\n"
end
end