在rspec * feature spec *中,如何查看* app *的完整堆栈跟踪?

时间:2014-02-08 22:14:30

标签: ruby-on-rails ruby rspec

使用-b CLI选项为功能规范提供完整的堆栈跟踪,但我需要我的应用的完整堆栈跟踪。我看了rspec-rails自述文件,但没有快乐。

 $ zeus rspec -b spec/features/redacted_spec.rb:29

 An error occurred in an after hook
   ActiveRecord::RecordNotFound: Couldn't find redacted with id=redacted [WHERE "redacted"."type" IN ('redacted')]
   occurred at /Users/redacted/.rbenv/versions/2.0.0-p353/lib/ruby/gems/2.0.0/gems/activerecord-4.0.2/lib/active_record/relation/finder_methods.rb:198:in `raise_record_not_found_exception!'

 F

 Failures:

   1) redacted on the redacted's page can edit
      Failure/Error: expect(page).to have_content "Program was successfully updated."
        expected to find text "Program was successfully updated." in "Internal Server Error Couldn't find redacted with id=redacted [WHERE \"redacted\".\"type\" IN ('redacted')] WEBrick/1.3.1 (Ruby/2.0.0/2013-11-22) at 127.0.0.1:52533"
      # /Users/redacted/.rbenv/versions/2.0.0-p353/lib/ruby/gems/2.0.0/gems/rspec-expectations-2.14.5/lib/rspec/expectations/fail_with.rb:32:in `fail_with'
      # /Users/redacted/.rbenv/versions/2.0.0-p353/lib/ruby/gems/2.0.0/gems/rspec-expectations-2.14.5/lib/rspec/expectations/handler.rb:36:in `handle_matcher'
      # /Users/redacted/.rbenv/versions/2.0.0-p353/lib/ruby/gems/2.0.0/gems/rspec-expectations-2.14.5/lib/rspec/expectations/expectation_target.rb:34:in `to'
      # ./spec/features/redacted_spec.rb:33:in `block (2 levels) in <top (required)>'
      # /Users/redacted/.rbenv/versions/2.0.0-p353/lib/ruby/gems/2.0.0/gems/rspec-core-2.14.7/lib/rspec/core/example.rb:114:in `instance_eval'
      .. snip dozens of lines ..
      # /Users/redacted/.rbenv/versions/2.0.0-p353/lib/ruby/gems/2.0.0/gems/zeus-0.13.3/lib/zeus.rb:62:in `go'
      # -e:1:in `<main>'

0 个答案:

没有答案