Skip to content

Commit

Permalink
config: fix rspec output from vim
Browse files Browse the repository at this point in the history
  • Loading branch information
yanovich committed Dec 30, 2011
1 parent e9e44e0 commit 0820694
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 1 deletion.
1 change: 1 addition & 0 deletions .rspec
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
--require ./config/rspec_formatter.rb --format CustomFormatter
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
check:
# rake test
rspec spec --drb
rspec spec --drb --color

PHONY: check
11 changes: 11 additions & 0 deletions config/rspec_formatter.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
require "rspec/core/formatters/progress_formatter"

class CustomFormatter < RSpec::Core::Formatters::ProgressFormatter
def dump_backtrace(example)
format_backtrace(example.execution_result[:exception].backtrace, example).each do |backtrace_info|
output.puts cyan("#{long_padding}#{backtrace_info}")
end
end
end

# vim:ts=2 sts=2 sw=2 et:

0 comments on commit 0820694

Please sign in to comment.