File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed
lib/ruby_lsp/ruby_lsp_rails Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -43,7 +43,7 @@ def on_call_node_enter(node)
4343 return unless first_arg . is_a? ( Prism ::StringNode )
4444
4545 test_name = first_arg . content
46- return if test_name . empty?
46+ test_name = "<empty test name>" if test_name . empty?
4747
4848 add_test_item ( node , test_name )
4949 end
Original file line number Diff line number Diff line change @@ -49,10 +49,10 @@ class EmptyTest < ActiveSupport::TestCase
4949 assert_equal ( 1 , items . length )
5050 test_class = items . first
5151 assert_equal ( "EmptyTest" , test_class [ :label ] )
52- assert_equal ( 1 , test_class [ :children ] . length )
52+ assert_equal ( 2 , test_class [ :children ] . length )
5353
5454 test_labels = test_class [ :children ] . map { |i | i [ :label ] }
55- refute_includes ( test_labels , "" )
55+ assert_includes ( test_labels , "<empty test name> " )
5656 assert_all_items_tagged_with ( items , :rails )
5757 end
5858 end
You can’t perform that action at this time.
0 commit comments