Skip to content

Commit 9cdf33b

Browse files
committed
Add test for lower-case class name warning
1 parent 27a9c41 commit 9cdf33b

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

test/test_rdoc_parser_ruby.rb

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -777,6 +777,15 @@ def test_parse_class_stopdoc
777777
assert_empty @top_level.classes.first.comment
778778
end
779779

780+
def test_parse_class_lower_name_warning
781+
@options.verbosity = 2
782+
out, err = capture_io do
783+
util_parser "class foo\nend"
784+
@parser.scan
785+
end
786+
assert_match /Expected class name or '<<'\. Got/, err
787+
end
788+
780789
def test_parse_multi_ghost_methods
781790
util_parser <<-'CLASS'
782791
class Foo

0 commit comments

Comments
 (0)