From 5b5c6378c7758af3b264972250f715c054ed0a37 Mon Sep 17 00:00:00 2001 From: mame Date: Mon, 28 Jun 2010 13:16:17 +0000 Subject: * test/rdoc/test_rdoc_ri_driver.rb (TestRDocRIDriver#test_formatter): fix a test accordingly to r28455. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@28460 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- test/rdoc/test_rdoc_ri_driver.rb | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'test/rdoc/test_rdoc_ri_driver.rb') diff --git a/test/rdoc/test_rdoc_ri_driver.rb b/test/rdoc/test_rdoc_ri_driver.rb index 51f2576cb4..8d64916088 100644 --- a/test/rdoc/test_rdoc_ri_driver.rb +++ b/test/rdoc/test_rdoc_ri_driver.rb @@ -498,15 +498,18 @@ Foo::Bar#bother def test_formatter driver = RDoc::RI::Driver.new - assert_instance_of @RM::ToAnsi, driver.formatter + io = Object.new + def io.tty?; true; end + + assert_instance_of @RM::ToAnsi, driver.formatter(io) driver.instance_variable_set :@paging, true - assert_instance_of @RM::ToBs, driver.formatter + assert_instance_of @RM::ToBs, driver.formatter(io) driver.instance_variable_set :@formatter_klass, @RM::ToHtml - assert_instance_of @RM::ToHtml, driver.formatter + assert_instance_of @RM::ToHtml, driver.formatter(io) end def test_method_type -- cgit v1.2.3