From e89241c92fbcf68b59d9efb50c21c5040e9f3156 Mon Sep 17 00:00:00 2001 From: rick Date: Sun, 17 May 2009 19:16:11 -0700 Subject: load the JSON Backend lazily. If the JSON gem is already loaded, use the JSONGem backend by default. --- activesupport/test/json/decoding_test.rb | 3 +++ 1 file changed, 3 insertions(+) (limited to 'activesupport/test') diff --git a/activesupport/test/json/decoding_test.rb b/activesupport/test/json/decoding_test.rb index 7e1bfcca84..09fd0d09ba 100644 --- a/activesupport/test/json/decoding_test.rb +++ b/activesupport/test/json/decoding_test.rb @@ -36,6 +36,9 @@ class TestJSONDecoding < ActiveSupport::TestCase %q({"b":["\u003ci\u003e","\u003cb\u003e","\u003cu\u003e"]}) => {'b' => ["","",""]} } + # load the default JSON backend + ActiveSupport::JSON.backend + backends = %w(Yaml) begin gem 'json', '>= 1.1' -- cgit v1.2.3