Project

General

Profile

Bug #3162

recent rdoc affects tests of rake

Added by mame (Yusuke Endoh) about 9 years ago. Updated about 8 years ago.

Status:
Closed
Priority:
Normal
Target version:
ruby -v:
ruby 1.9.2dev (2010-04-17 trunk 27376) [i686-linux]
Backport:
[ruby-core:29571]

Description

=begin
Hi, Eric Hodel

Now, lib/rdoc/task.rb replaces Rake::RDocTask with RDoc::Task,
which seems to cause failures of tests of rake:

 1) Failure:

test_inline_source_is_enabled_by_default(Rake::TestRDocTask) [/home/mame/work/ruby/test/rake/test_rdoc_task.rb:65]:
Failed assertion, no message given.

 2) Error:

test_inline_source_option_can_be_disabled(Rake::TestRDocTask):
NoMethodError: undefined method inline_source=' for #<RDoc::Task:0x83bfe90>
/home/mame/work/ruby/test/rake/test_rdoc_task.rb:81:in
test_inline_source_option_can_be_disabled'

I don't know why the replacement (compatibility layer?) is needed,
but if I delete it, the failures don't occur.

diff --git a/lib/rdoc/task.rb b/lib/rdoc/task.rb
index 005c516..ac36bdb 100644
--- a/lib/rdoc/task.rb
+++ b/lib/rdoc/task.rb
@@ -251,7 +251,7 @@ module Rake
##
# For backwards compatibility

  • RDocTask = RDoc::Task
  • #RDocTask = RDoc::Task

end
# :startdoc:

--
Yusuke Endoh mame@tsg.ne.jp
=end


Related issues

Is duplicate of Ruby trunk - Bug #3076: lib/rake/rdoctask.rb should be removedClosed04/01/2010Actions

History

#1

Updated by drbrain (Eric Hodel) about 9 years ago

=begin
I think this issue should be resolved by removing rake/rdoctask (issue #3076). Rake should not have the responsibility of knowing the internals of RDoc.

Instead, rake/rdoctask.rb should be something as small as:

require 'rdoc/task'

and possibly a warning in order to maintain backwards compatibility.
=end

#2

Updated by mame (Yusuke Endoh) about 9 years ago

=begin
Hi,

2010/4/17 Eric Hodel redmine@ruby-lang.org:

I think this issue should be resolved by removing rake/rdoctask (issue #3076).  Rake should not have the responsibility of knowing the internals of RDoc.

Ah, sorry. I didn't realize the ticket #3076.
Jim Weirich, what do you think about the ticket?

--
Yusuke ENDOH mame@tsg.ne.jp

=end

#3

Updated by mame (Yusuke Endoh) about 9 years ago

  • Status changed from Open to Closed

=begin
Hi,

This is fixed by nobu at r27589. So I close this ticket.

Jim Weirich, please confirm the change.
If you think the fix is good, please backport to rake trunk.
If you think the fix has a problem, please re-fix by yourself.

--
Yusuke Endoh mame@tsg.ne.jp
=end

Also available in: Atom PDF