mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
Fix order dependent tests
Restore default ActiveSupport::XmlMini.backend after tests
This commit is contained in:
parent
64202abc3d
commit
c48cbb02d7
1 changed files with 10 additions and 2 deletions
|
@ -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
|
||||
|
|
Loading…
Reference in a new issue