class Tryouts::CLI::VerboseFormatter

def show_test_source_code(test_case)

def show_test_source_code(test_case)
  puts indent_text('Source code:', 3)
  # Use pre-captured source lines from parsing
  start_line = test_case.line_range.first
  test_case.source_lines.each_with_index do |line_content, index|
    line_num     = start_line + index
    line_display = format('%3d: %s', line_num + 1, line_content)
    # Highlight expectation lines by checking if this line
    # contains the expectation syntax
    if line_content.match?(/^\s*#\s*=>\s*/)
      line_display = Console.color(:yellow, line_display)
    end
    puts indent_text(line_display, 4)
  end
  puts
end