tests/test_json_generate.rb in json-1.1.3 vs tests/test_json_generate.rb in json-1.1.4
- old
+ new
@@ -1,12 +1,18 @@
+#!/usr/bin/env ruby
+# -*- coding: utf-8 -*-
+
require 'test/unit'
-require 'json'
+case ENV['JSON']
+when 'pure' then require 'json/pure'
+when 'ext' then require 'json/ext'
+else require 'json'
+end
class TC_JSONGenerate < Test::Unit::TestCase
include JSON
def setup
- $KCODE = 'UTF8'
@hash = {
'a' => 2,
'b' => 3.141,
'c' => 'c',
'd' => [ 1, "b", 3.14 ],