Browse files

clear formatters between runs

- Closes #435.
  • Loading branch information...
1 parent 78024c2 commit 371fc523c36b730174346afc63a96d1397330104 @johnbintz johnbintz committed with dchelimsky Aug 6, 2011
Showing with 9 additions and 0 deletions.
  1. +1 −0 lib/rspec/core/configuration.rb
  2. +8 −0 spec/rspec/core/configuration_spec.rb
View
1 lib/rspec/core/configuration.rb
@@ -66,6 +66,7 @@ def initialize
def reset
@reporter = nil
+ @formatters = []
end
# :call-seq:
View
8 spec/rspec/core/configuration_spec.rb
@@ -886,5 +886,13 @@ def metadata_hash(*args)
end
end
+ describe "#reset" do
+ it "resets the reporter and formatters" do
+ config.reporter
+ config.formatters.should_not be_empty
+ config.reset
+ config.formatters.should be_empty
+ end
+ end
end
end

0 comments on commit 371fc52

Please sign in to comment.