diff options
Diffstat (limited to 'test')
-rw-r--r-- | test/rdoc/test_rdoc_options.rb | 9 | ||||
-rw-r--r-- | test/rdoc/test_rdoc_parser.rb | 7 |
2 files changed, 16 insertions, 0 deletions
diff --git a/test/rdoc/test_rdoc_options.rb b/test/rdoc/test_rdoc_options.rb index 763f50b5f0..2f74f45b45 100644 --- a/test/rdoc/test_rdoc_options.rb +++ b/test/rdoc/test_rdoc_options.rb @@ -337,6 +337,15 @@ file 'unreadable' not readable $LOAD_PATH.replace orig_LOAD_PATH end + def test_parse_extension_alias + out, err = capture_io do + @options.parse %w[--extension foobar=rdoc] + end + + assert_empty out + assert_empty err + end + def test_setup_generator test_generator = Class.new do def self.setup_options op diff --git a/test/rdoc/test_rdoc_parser.rb b/test/rdoc/test_rdoc_parser.rb index 37d3b67323..49e845e27b 100644 --- a/test/rdoc/test_rdoc_parser.rb +++ b/test/rdoc/test_rdoc_parser.rb @@ -57,6 +57,13 @@ class TestRDocParser < MiniTest::Unit::TestCase readme_file_name = File.expand_path '../README', __FILE__ assert_equal @RP::Simple, @RP.can_parse(readme_file_name) + + jtest_largerdoc_file_name = File.expand_path '../test.ja.largedoc', __FILE__ + assert_nil @RP.can_parse(jtest_largerdoc_file_name) + + @RP.alias_extension("rdoc", "largedoc") + assert_equal @RP::Simple, @RP.can_parse(jtest_largerdoc_file_name) + end ## |