1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

[ruby/rdoc] Relative loading for easier development (https://github.com/ruby/rdoc/pull/821)

This patch makes sure we only load relative code. Hence when coding or
testing rdoc, we'll be sure to always be using the correct code.

Discussion started at https://github.com/ruby/rdoc/pull/817.

Signed-off-by: Ulysse Buonomo <buonomo.ulysse@gmail.com>

https://github.com/ruby/rdoc/commit/aa41bd48eb

Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org>
This commit is contained in:
Ulysse Buonomo 2022-02-10 03:31:06 +01:00 committed by Nobuyoshi Nakada
parent 08137c5dd9
commit 5348a34504
41 changed files with 161 additions and 162 deletions

View file

@ -62,7 +62,7 @@ module RDoc
class Error < RuntimeError; end class Error < RuntimeError; end
require 'rdoc/version' require_relative 'rdoc/version'
## ##
# Method visibilities # Method visibilities
@ -141,61 +141,61 @@ module RDoc
end end
end end
autoload :RDoc, 'rdoc/rdoc' autoload :RDoc, "#{__dir__}/rdoc/rdoc"
autoload :CrossReference, 'rdoc/cross_reference' autoload :CrossReference, "#{__dir__}/rdoc/cross_reference"
autoload :ERBIO, 'rdoc/erbio' autoload :ERBIO, "#{__dir__}/rdoc/erbio"
autoload :ERBPartial, 'rdoc/erb_partial' autoload :ERBPartial, "#{__dir__}/rdoc/erb_partial"
autoload :Encoding, 'rdoc/encoding' autoload :Encoding, "#{__dir__}/rdoc/encoding"
autoload :Generator, 'rdoc/generator' autoload :Generator, "#{__dir__}/rdoc/generator"
autoload :Options, 'rdoc/options' autoload :Options, "#{__dir__}/rdoc/options"
autoload :Parser, 'rdoc/parser' autoload :Parser, "#{__dir__}/rdoc/parser"
autoload :Servlet, 'rdoc/servlet' autoload :Servlet, "#{__dir__}/rdoc/servlet"
autoload :RI, 'rdoc/ri' autoload :RI, "#{__dir__}/rdoc/ri"
autoload :Stats, 'rdoc/stats' autoload :Stats, "#{__dir__}/rdoc/stats"
autoload :Store, 'rdoc/store' autoload :Store, "#{__dir__}/rdoc/store"
autoload :Task, 'rdoc/task' autoload :Task, "#{__dir__}/rdoc/task"
autoload :Text, 'rdoc/text' autoload :Text, "#{__dir__}/rdoc/text"
autoload :Markdown, 'rdoc/markdown' autoload :Markdown, "#{__dir__}/rdoc/markdown"
autoload :Markup, 'rdoc/markup' autoload :Markup, "#{__dir__}/rdoc/markup"
autoload :RD, 'rdoc/rd' autoload :RD, "#{__dir__}/rdoc/rd"
autoload :TomDoc, 'rdoc/tom_doc' autoload :TomDoc, "#{__dir__}/rdoc/tom_doc"
autoload :KNOWN_CLASSES, 'rdoc/known_classes' autoload :KNOWN_CLASSES, "#{__dir__}/rdoc/known_classes"
autoload :TokenStream, 'rdoc/token_stream' autoload :TokenStream, "#{__dir__}/rdoc/token_stream"
autoload :Comment, 'rdoc/comment' autoload :Comment, "#{__dir__}/rdoc/comment"
require 'rdoc/i18n' require_relative 'rdoc/i18n'
# code objects # code objects
# #
# We represent the various high-level code constructs that appear in Ruby # We represent the various high-level code constructs that appear in Ruby
# programs: classes, modules, methods, and so on. # programs: classes, modules, methods, and so on.
autoload :CodeObject, 'rdoc/code_object' autoload :CodeObject, "#{__dir__}/rdoc/code_object"
autoload :Context, 'rdoc/context' autoload :Context, "#{__dir__}/rdoc/context"
autoload :TopLevel, 'rdoc/top_level' autoload :TopLevel, "#{__dir__}/rdoc/top_level"
autoload :AnonClass, 'rdoc/anon_class' autoload :AnonClass, "#{__dir__}/rdoc/anon_class"
autoload :ClassModule, 'rdoc/class_module' autoload :ClassModule, "#{__dir__}/rdoc/class_module"
autoload :NormalClass, 'rdoc/normal_class' autoload :NormalClass, "#{__dir__}/rdoc/normal_class"
autoload :NormalModule, 'rdoc/normal_module' autoload :NormalModule, "#{__dir__}/rdoc/normal_module"
autoload :SingleClass, 'rdoc/single_class' autoload :SingleClass, "#{__dir__}/rdoc/single_class"
autoload :Alias, 'rdoc/alias' autoload :Alias, "#{__dir__}/rdoc/alias"
autoload :AnyMethod, 'rdoc/any_method' autoload :AnyMethod, "#{__dir__}/rdoc/any_method"
autoload :MethodAttr, 'rdoc/method_attr' autoload :MethodAttr, "#{__dir__}/rdoc/method_attr"
autoload :GhostMethod, 'rdoc/ghost_method' autoload :GhostMethod, "#{__dir__}/rdoc/ghost_method"
autoload :MetaMethod, 'rdoc/meta_method' autoload :MetaMethod, "#{__dir__}/rdoc/meta_method"
autoload :Attr, 'rdoc/attr' autoload :Attr, "#{__dir__}/rdoc/attr"
autoload :Constant, 'rdoc/constant' autoload :Constant, "#{__dir__}/rdoc/constant"
autoload :Mixin, 'rdoc/mixin' autoload :Mixin, "#{__dir__}/rdoc/mixin"
autoload :Include, 'rdoc/include' autoload :Include, "#{__dir__}/rdoc/include"
autoload :Extend, 'rdoc/extend' autoload :Extend, "#{__dir__}/rdoc/extend"
autoload :Require, 'rdoc/require' autoload :Require, "#{__dir__}/rdoc/require"
end end

View file

@ -2,5 +2,4 @@
# This file was used to load all the RDoc::CodeObject subclasses at once. Now # This file was used to load all the RDoc::CodeObject subclasses at once. Now
# autoload handles this. # autoload handles this.
require 'rdoc' require_relative '../rdoc'

View file

@ -1261,6 +1261,6 @@ class RDoc::Context < RDoc::CodeObject
klass klass
end end
autoload :Section, 'rdoc/context/section' autoload :Section, "#{__dir__}/context/section"
end end

View file

@ -41,11 +41,11 @@
module RDoc::Generator module RDoc::Generator
autoload :Markup, 'rdoc/generator/markup' autoload :Markup, "#{__dir__}/generator/markup"
autoload :Darkfish, 'rdoc/generator/darkfish' autoload :Darkfish, "#{__dir__}/generator/darkfish"
autoload :JsonIndex, 'rdoc/generator/json_index' autoload :JsonIndex, "#{__dir__}/generator/json_index"
autoload :RI, 'rdoc/generator/ri' autoload :RI, "#{__dir__}/generator/ri"
autoload :POT, 'rdoc/generator/pot' autoload :POT, "#{__dir__}/generator/pot"
end end

View file

@ -4,7 +4,7 @@
module RDoc::I18n module RDoc::I18n
autoload :Locale, 'rdoc/i18n/locale' autoload :Locale, "#{__dir__}/i18n/locale"
require_relative 'i18n/text' require_relative 'i18n/text'
end end

View file

@ -199,6 +199,7 @@ class RDoc::Markdown
@result = nil @result = nil
@failed_rule = nil @failed_rule = nil
@failing_rule_offset = -1 @failing_rule_offset = -1
@line_offsets = nil
setup_foreign_grammar setup_foreign_grammar
end end
@ -215,17 +216,32 @@ class RDoc::Markdown
target + 1 target + 1
end end
def current_line(target=pos) if [].respond_to? :bsearch_index
cur_offset = 0 def current_line(target=pos)
cur_line = 0 unless @line_offsets
@line_offsets = []
total = 0
string.each_line do |line|
total += line.size
@line_offsets << total
end
end
string.each_line do |line| @line_offsets.bsearch_index {|x| x >= target } + 1 || -1
cur_line += 1
cur_offset += line.size
return cur_line if cur_offset >= target
end end
else
def current_line(target=pos)
cur_offset = 0
cur_line = 0
-1 string.each_line do |line|
cur_line += 1
cur_offset += line.size
return cur_line if cur_offset >= target
end
-1
end
end end
def lines def lines
@ -533,11 +549,11 @@ class RDoc::Markdown
require 'rdoc' require_relative '../rdoc'
require 'rdoc/markup/to_joined_paragraph' require_relative 'markup/to_joined_paragraph'
require 'rdoc/markdown/entities' require_relative 'markdown/entities'
require 'rdoc/markdown/literals' require_relative 'markdown/literals'
## ##
# Supported extensions # Supported extensions

View file

@ -822,46 +822,45 @@ https://github.com/ruby/rdoc/issues
document.accept formatter document.accept formatter
end end
autoload :Parser, 'rdoc/markup/parser' autoload :Parser, "#{__dir__}/markup/parser"
autoload :PreProcess, 'rdoc/markup/pre_process' autoload :PreProcess, "#{__dir__}/markup/pre_process"
# Inline markup classes # Inline markup classes
autoload :AttrChanger, 'rdoc/markup/attr_changer' autoload :AttrChanger, "#{__dir__}/markup/attr_changer"
autoload :AttrSpan, 'rdoc/markup/attr_span' autoload :AttrSpan, "#{__dir__}/markup/attr_span"
autoload :Attributes, 'rdoc/markup/attributes' autoload :Attributes, "#{__dir__}/markup/attributes"
autoload :AttributeManager, 'rdoc/markup/attribute_manager' autoload :AttributeManager, "#{__dir__}/markup/attribute_manager"
autoload :RegexpHandling, 'rdoc/markup/regexp_handling' autoload :RegexpHandling, "#{__dir__}/markup/regexp_handling"
# RDoc::Markup AST # RDoc::Markup AST
autoload :BlankLine, 'rdoc/markup/blank_line' autoload :BlankLine, "#{__dir__}/markup/blank_line"
autoload :BlockQuote, 'rdoc/markup/block_quote' autoload :BlockQuote, "#{__dir__}/markup/block_quote"
autoload :Document, 'rdoc/markup/document' autoload :Document, "#{__dir__}/markup/document"
autoload :HardBreak, 'rdoc/markup/hard_break' autoload :HardBreak, "#{__dir__}/markup/hard_break"
autoload :Heading, 'rdoc/markup/heading' autoload :Heading, "#{__dir__}/markup/heading"
autoload :Include, 'rdoc/markup/include' autoload :Include, "#{__dir__}/markup/include"
autoload :IndentedParagraph, 'rdoc/markup/indented_paragraph' autoload :IndentedParagraph, "#{__dir__}/markup/indented_paragraph"
autoload :List, 'rdoc/markup/list' autoload :List, "#{__dir__}/markup/list"
autoload :ListItem, 'rdoc/markup/list_item' autoload :ListItem, "#{__dir__}/markup/list_item"
autoload :Paragraph, 'rdoc/markup/paragraph' autoload :Paragraph, "#{__dir__}/markup/paragraph"
autoload :Table, 'rdoc/markup/table' autoload :Table, "#{__dir__}/markup/table"
autoload :Raw, 'rdoc/markup/raw' autoload :Raw, "#{__dir__}/markup/raw"
autoload :Rule, 'rdoc/markup/rule' autoload :Rule, "#{__dir__}/markup/rule"
autoload :Verbatim, 'rdoc/markup/verbatim' autoload :Verbatim, "#{__dir__}/markup/verbatim"
# Formatters # Formatters
autoload :Formatter, 'rdoc/markup/formatter' autoload :Formatter, "#{__dir__}/markup/formatter"
autoload :ToAnsi, 'rdoc/markup/to_ansi' autoload :ToAnsi, "#{__dir__}/markup/to_ansi"
autoload :ToBs, 'rdoc/markup/to_bs' autoload :ToBs, "#{__dir__}/markup/to_bs"
autoload :ToHtml, 'rdoc/markup/to_html' autoload :ToHtml, "#{__dir__}/markup/to_html"
autoload :ToHtmlCrossref, 'rdoc/markup/to_html_crossref' autoload :ToHtmlCrossref, "#{__dir__}/markup/to_html_crossref"
autoload :ToHtmlSnippet, 'rdoc/markup/to_html_snippet' autoload :ToHtmlSnippet, "#{__dir__}/markup/to_html_snippet"
autoload :ToLabel, 'rdoc/markup/to_label' autoload :ToLabel, "#{__dir__}/markup/to_label"
autoload :ToMarkdown, 'rdoc/markup/to_markdown' autoload :ToMarkdown, "#{__dir__}/markup/to_markdown"
autoload :ToRdoc, 'rdoc/markup/to_rdoc' autoload :ToRdoc, "#{__dir__}/markup/to_rdoc"
autoload :ToTableOfContents, 'rdoc/markup/to_table_of_contents' autoload :ToTableOfContents, "#{__dir__}/markup/to_table_of_contents"
autoload :ToTest, 'rdoc/markup/to_test' autoload :ToTest, "#{__dir__}/markup/to_test"
autoload :ToTtOnly, 'rdoc/markup/to_tt_only' autoload :ToTtOnly, "#{__dir__}/markup/to_tt_only"
end end

View file

@ -263,8 +263,8 @@ class RDoc::Parser
@preprocess.options = @options @preprocess.options = @options
end end
autoload :RubyTools, 'rdoc/parser/ruby_tools' autoload :RubyTools, "#{__dir__}/parser/ruby_tools"
autoload :Text, 'rdoc/parser/text' autoload :Text, "#{__dir__}/parser/text"
end end

View file

@ -92,9 +92,8 @@ class RDoc::RD
document document
end end
autoload :BlockParser, 'rdoc/rd/block_parser' autoload :BlockParser, "#{__dir__}/rd/block_parser"
autoload :InlineParser, 'rdoc/rd/inline_parser' autoload :InlineParser, "#{__dir__}/rd/inline_parser"
autoload :Inline, 'rdoc/rd/inline' autoload :Inline, "#{__dir__}/rd/inline"
end end

View file

@ -1,5 +1,5 @@
# frozen_string_literal: true # frozen_string_literal: true
require 'rdoc' require_relative '../rdoc'
require 'find' require 'find'
require 'fileutils' require 'fileutils'

View file

@ -1,5 +1,5 @@
# frozen_string_literal: true # frozen_string_literal: true
require 'rdoc' require_relative '../rdoc'
## ##
# Namespace for the ri command line tool's implementation. # Namespace for the ri command line tool's implementation.
@ -13,9 +13,8 @@ module RDoc::RI
class Error < RDoc::Error; end class Error < RDoc::Error; end
autoload :Driver, 'rdoc/ri/driver' autoload :Driver, "#{__dir__}/ri/driver"
autoload :Paths, 'rdoc/ri/paths' autoload :Paths, "#{__dir__}/ri/paths"
autoload :Store, 'rdoc/ri/store' autoload :Store, "#{__dir__}/ri/store"
end end

View file

@ -12,7 +12,7 @@ begin
rescue LoadError rescue LoadError
end end
require 'rdoc' require_relative '../../rdoc'
## ##
# For RubyGems backwards compatibility # For RubyGems backwards compatibility

View file

@ -1,7 +1,7 @@
# frozen_string_literal: true # frozen_string_literal: true
require 'rubygems/user_interaction' require 'rubygems/user_interaction'
require 'fileutils' require 'fileutils'
require 'rdoc' require_relative '../rdoc'
## ##
# Gem::RDoc provides methods to generate RDoc and ri data for installed gems # Gem::RDoc provides methods to generate RDoc and ri data for installed gems

View file

@ -1,5 +1,5 @@
# frozen_string_literal: true # frozen_string_literal: true
require 'rdoc' require_relative '../rdoc'
require 'erb' require 'erb'
require 'time' require 'time'
require 'json' require 'json'

View file

@ -454,9 +454,8 @@ class RDoc::Stats
[params.length, undoc] [params.length, undoc]
end end
autoload :Quiet, 'rdoc/stats/quiet' autoload :Quiet, "#{__dir__}/stats/quiet"
autoload :Normal, 'rdoc/stats/normal' autoload :Normal, "#{__dir__}/stats/normal"
autoload :Verbose, 'rdoc/stats/verbose' autoload :Verbose, "#{__dir__}/stats/verbose"
end end

View file

@ -32,7 +32,7 @@ begin
rescue Gem::LoadError rescue Gem::LoadError
end unless defined?(Rake) end unless defined?(Rake)
require 'rdoc' require_relative '../rdoc'
require 'rake' require 'rake'
require 'rake/tasklib' require 'rake/tasklib'

View file

@ -1,3 +1,5 @@
# frozen_string_literal: true
module RDoc module RDoc
## ##

View file

@ -41,4 +41,3 @@ rescue Exception => e
exit 1 exit 1
end end

View file

@ -1,5 +1,5 @@
# frozen_string_literal: true # frozen_string_literal: true
require_relative './support/test_case' require_relative 'support/test_case'
require_relative './support/formatter_test_case' require_relative 'support/formatter_test_case'
require_relative './support/text_formatter_test_case' require_relative 'support/text_formatter_test_case'

View file

@ -13,7 +13,7 @@ require 'tempfile'
require 'tmpdir' require 'tmpdir'
require 'stringio' require 'stringio'
require 'rdoc' require_relative '../../../lib/rdoc'
## ##
# RDoc::TestCase is an abstract TestCase to provide common setup and teardown # RDoc::TestCase is an abstract TestCase to provide common setup and teardown

View file

@ -1,5 +1,5 @@
# frozen_string_literal: true # frozen_string_literal: true
require File.expand_path '../xref_test_case', __FILE__ require_relative 'xref_test_case'
class TestRDocAlias < XrefTestCase class TestRDocAlias < XrefTestCase
@ -11,4 +11,3 @@ class TestRDocAlias < XrefTestCase
end end
end end

View file

@ -1,5 +1,5 @@
# frozen_string_literal: true # frozen_string_literal: true
require File.expand_path '../xref_test_case', __FILE__ require_relative 'xref_test_case'
class TestRDocAnyMethod < XrefTestCase class TestRDocAnyMethod < XrefTestCase

View file

@ -1,5 +1,5 @@
# frozen_string_literal: true # frozen_string_literal: true
require File.expand_path '../xref_test_case', __FILE__ require_relative 'xref_test_case'
class TestRDocClassModule < XrefTestCase class TestRDocClassModule < XrefTestCase
@ -1501,4 +1501,3 @@ class TestRDocClassModule < XrefTestCase
end end
end end

View file

@ -1,7 +1,7 @@
# coding: US-ASCII # coding: US-ASCII
# frozen_string_literal: true # frozen_string_literal: true
require File.expand_path '../xref_test_case', __FILE__ require_relative 'xref_test_case'
class TestRDocCodeObject < XrefTestCase class TestRDocCodeObject < XrefTestCase

View file

@ -1,5 +1,5 @@
# frozen_string_literal: true # frozen_string_literal: true
require File.expand_path '../xref_test_case', __FILE__ require_relative 'xref_test_case'
class TestRDocConstant < XrefTestCase class TestRDocConstant < XrefTestCase

View file

@ -1,5 +1,5 @@
# frozen_string_literal: true # frozen_string_literal: true
require File.expand_path '../xref_test_case', __FILE__ require_relative 'xref_test_case'
class TestRDocContext < XrefTestCase class TestRDocContext < XrefTestCase

View file

@ -1,5 +1,5 @@
# frozen_string_literal: true # frozen_string_literal: true
require File.expand_path '../xref_test_case', __FILE__ require_relative 'xref_test_case'
class TestRDocCrossReference < XrefTestCase class TestRDocCrossReference < XrefTestCase
OPERATOR_METHODS = %w'== === != =~ !~ < > <= >= <=> [] []= << >> -@ +@ ! - + * / % ** !@ ` | & ^ ~' OPERATOR_METHODS = %w'== === != =~ !~ < > <= >= <=> [] []= << >> -@ +@ ! - + * / % ** !@ ` | & ^ ~'
@ -215,4 +215,3 @@ class TestRDocCrossReference < XrefTestCase
end end
end end

View file

@ -1,5 +1,5 @@
# frozen_string_literal: true # frozen_string_literal: true
require File.expand_path '../xref_test_case', __FILE__ require_relative 'xref_test_case'
class TestRDocExtend < XrefTestCase class TestRDocExtend < XrefTestCase
@ -92,4 +92,3 @@ class TestRDocExtend < XrefTestCase
end end
end end

View file

@ -1,5 +1,5 @@
# frozen_string_literal: true # frozen_string_literal: true
require File.expand_path '../xref_test_case', __FILE__ require_relative 'xref_test_case'
class TestRDocInclude < XrefTestCase class TestRDocInclude < XrefTestCase
@ -107,4 +107,3 @@ class TestRDocInclude < XrefTestCase
end end
end end

View file

@ -2,8 +2,8 @@
# frozen_string_literal: true # frozen_string_literal: true
require_relative 'helper' require_relative 'helper'
require 'rdoc/markup/block_quote' require_relative '../../lib/rdoc/markup/block_quote'
require 'rdoc/markdown' require_relative '../../lib/rdoc/markdown'
class TestRDocMarkdown < RDoc::TestCase class TestRDocMarkdown < RDoc::TestCase
@ -1068,4 +1068,3 @@ and an extra note.[^2]
end end
end end

View file

@ -2,8 +2,8 @@
require_relative 'helper' require_relative 'helper'
require 'pp' require 'pp'
require 'rdoc' require_relative '../../lib/rdoc'
require 'rdoc/markdown' require_relative '../../lib/rdoc/markdown'
class TestRDocMarkdownTest < RDoc::TestCase class TestRDocMarkdownTest < RDoc::TestCase

View file

@ -1,5 +1,5 @@
# frozen_string_literal: true # frozen_string_literal: true
require File.expand_path '../xref_test_case', __FILE__ require_relative 'xref_test_case'
class TestRDocMarkupToHtmlCrossref < XrefTestCase class TestRDocMarkupToHtmlCrossref < XrefTestCase
@ -260,4 +260,3 @@ class TestRDocMarkupToHtmlCrossref < XrefTestCase
end end
end end

View file

@ -1,5 +1,5 @@
# frozen_string_literal: true # frozen_string_literal: true
require File.expand_path '../xref_test_case', __FILE__ require_relative 'xref_test_case'
class TestRDocMethodAttr < XrefTestCase class TestRDocMethodAttr < XrefTestCase
@ -191,4 +191,3 @@ class TestRDocMethodAttr < XrefTestCase
end end
end end

View file

@ -1,5 +1,5 @@
# frozen_string_literal: true # frozen_string_literal: true
require File.expand_path '../xref_test_case', __FILE__ require_relative 'xref_test_case'
class TestRDocNormalClass < XrefTestCase class TestRDocNormalClass < XrefTestCase
@ -45,4 +45,3 @@ class TestRDocNormalClass < XrefTestCase
end end
end end

View file

@ -1,5 +1,5 @@
# frozen_string_literal: true # frozen_string_literal: true
require File.expand_path '../xref_test_case', __FILE__ require_relative 'xref_test_case'
class TestRDocNormalModule < XrefTestCase class TestRDocNormalModule < XrefTestCase
@ -40,4 +40,3 @@ class TestRDocNormalModule < XrefTestCase
end end
end end

View file

@ -1,5 +1,5 @@
# frozen_string_literal: true # frozen_string_literal: true
require File.expand_path '../xref_test_case', __FILE__ require_relative 'xref_test_case'
class TestRDocRequire < XrefTestCase class TestRDocRequire < XrefTestCase
@ -23,4 +23,3 @@ class TestRDocRequire < XrefTestCase
end end
end end

View file

@ -32,8 +32,8 @@ class TestRDocRIDriver < RDoc::TestCase
end end
def teardown def teardown
ENV['RI'] = @orig_ri defined?(@orig_ri) and ENV['RI'] = @orig_ri
FileUtils.rm_rf @tmpdir defined?(@tmpdir) and FileUtils.rm_rf @tmpdir
super super
end end

View file

@ -1,9 +1,9 @@
# frozen_string_literal: true # frozen_string_literal: true
require "rubygems" require 'rubygems'
require "fileutils" require 'fileutils'
require "tmpdir" require 'tmpdir'
require 'rdoc/rubygems_hook' require_relative '../../lib/rdoc/rubygems_hook'
require "test/unit" require 'test/unit'
class TestRDocRubygemsHook < Test::Unit::TestCase class TestRDocRubygemsHook < Test::Unit::TestCase
def setup def setup

View file

@ -1,5 +1,5 @@
# frozen_string_literal: true # frozen_string_literal: true
require File.expand_path '../xref_test_case', __FILE__ require_relative 'xref_test_case'
class TestRDocStore < XrefTestCase class TestRDocStore < XrefTestCase

View file

@ -171,4 +171,3 @@ class TestRDocTask < RDoc::TestCase
end end
end if defined?(Rake::Task) end if defined?(Rake::Task)

View file

@ -1,5 +1,5 @@
# frozen_string_literal: true # frozen_string_literal: true
require File.expand_path '../xref_test_case', __FILE__ require_relative 'xref_test_case'
class TestRDocTopLevel < XrefTestCase class TestRDocTopLevel < XrefTestCase
@ -288,4 +288,3 @@ class TestRDocTopLevel < XrefTestCase
end end
end end