Sha256: 8c7c9aacbc9070c95632a3c5e2132a05e916f70449d07f6e9e2ba73e48802153
Contents?: true
Size: 506 Bytes
Versions: 2
Compression:
Stored size: 506 Bytes
Contents
class TestUI < Vagrant::UI::Interface attr_reader :messages METHODS = [:clear_line, :report_progress, :warn, :error, :info, :success] def initialize super @messages = METHODS.each_with_object({}) { |m, h| h[m] = [] } end def ask(*args) super # Automated tests should not depend on user input, obviously. raise Errors::UIExpectsTTY end METHODS.each do |method| define_method(method) do |*args|#message, *opts| @messages[method].push args[0] end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
vagrant-lxc-0.8.0 | spec/acceptance/support/test_ui.rb |
vagrant-lxc-0.7.0 | spec/acceptance/support/test_ui.rb |