aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport
diff options
context:
space:
mode:
authorArun Agrawal <arunagw@gmail.com>2013-09-09 17:11:16 +0200
committerArun Agrawal <arunagw@gmail.com>2013-09-09 17:11:16 +0200
commit6f0b1ae04e2d4139563287140a81f553d9f46a7c (patch)
tree033cdc238d895c74702f6060b7c6bbdf94059a1e /activesupport
parent17e860c14eea4ea599c93f77252eec37ee0f687d (diff)
downloadrails-6f0b1ae04e2d4139563287140a81f553d9f46a7c.tar.gz
rails-6f0b1ae04e2d4139563287140a81f553d9f46a7c.tar.bz2
rails-6f0b1ae04e2d4139563287140a81f553d9f46a7c.zip
Fix order dependent test
see c48cbb02d7e6f585e31b404c0c363f0d6b586811
Diffstat (limited to 'activesupport')
-rw-r--r--activesupport/test/xml_mini_test.rb12
1 files changed, 10 insertions, 2 deletions
diff --git a/activesupport/test/xml_mini_test.rb b/activesupport/test/xml_mini_test.rb
index a025279e16..d992028323 100644
--- a/activesupport/test/xml_mini_test.rb
+++ b/activesupport/test/xml_mini_test.rb
@@ -106,7 +106,11 @@ module XmlMiniTest
module Nokogiri end
setup do
- @xml = ActiveSupport::XmlMini
+ @xml, @default_backend = ActiveSupport::XmlMini, ActiveSupport::XmlMini.backend
+ end
+
+ teardown do
+ ActiveSupport::XmlMini.backend = @default_backend
end
test "#with_backend should switch backend and then switch back" do
@@ -135,7 +139,11 @@ module XmlMiniTest
module LibXML end
setup do
- @xml = ActiveSupport::XmlMini
+ @xml, @default_backend = ActiveSupport::XmlMini, ActiveSupport::XmlMini.backend
+ end
+
+ teardown do
+ ActiveSupport::XmlMini.backend = @default_backend
end
test "#with_backend should be thread-safe" do