Flowdock
method

filter_backtrace

Importance_0
Ruby latest stable (v1_9_3_392) - 0 notes - Class: MiniTest
filter_backtrace(bt) public

No documentation

This method has no description. You can help the Ruby community by adding new notes.

Hide source
# File lib/minitest/unit.rb, line 43
  def self.filter_backtrace bt # :nodoc:
    return ["No backtrace"] unless bt

    new_bt = []

    unless $DEBUG then
      bt.each do |line|
        break if line.rindex MINI_DIR, 0
        new_bt << line
      end

      new_bt = bt.reject { |line| line.rindex MINI_DIR, 0 } if new_bt.empty?
      new_bt = bt.dup if new_bt.empty?
    else
      new_bt = bt.dup
    end

    new_bt
  end
Register or log in to add new notes.