How to get rspec-2 to give the full trace associated with a test failure?

后端 未结 6 2016
独厮守ぢ
独厮守ぢ 2020-12-13 05:21

Right now if I run my test suite using rake spec I get an error:

1) SegmentsController GET \'index\' should work
   Failure/Error: get \'index\'
   u         


        
6条回答
  •  误落风尘
    2020-12-13 06:06

    One more option when all else fails is to just add a rescue block and print out the stack try or add a binding pry statement there and use show-stack.

    rescue Exception => e
      puts ""
      puts e.backtrace
      puts ""
    

提交回复
热议问题