# File lib/action_controller/assertions.rb, line 294 def clean_backtrace(&block) begin yield rescue AssertionFailedError => e path = File.expand_path(__FILE__) raise AssertionFailedError, e.message, e.backtrace.reject { |line| File.expand_path(line) =~ /#{path}/ } end end