https://github.com/plentz/jruby_report/blob/master/ok_json_test.rb
~/Projects/opensource/jruby_report (master) $ ruby -I. ok_json_test.rb
Run options: --seed 31809
# Running tests:
"\xEF\xBF\xBD"
..F
Finished tests in 0.049639s, 60.4364 tests/s, 60.4364 assertions/s.
1) Failure:
test_json_encode(OkJsonTest) [ok_json_test.rb:14]:
Expected: "{\"message\":\"á\"}"
Actual: "{\"message\":\"\\ufffd\"}"
3 tests, 3 assertions, 1 failures, 0 errors, 0 skips
to this
~/Projects/opensource/jruby_report (master) $ ruby -I. ok_json_test.rb
Run options: --seed 3567
# Running tests:
.FF
Finished tests in 0.028424s, 105.5446 tests/s, 105.5446 assertions/s.
1) Failure:
test_decode_bad(OkJsonTest) [ok_json_test.rb:24]:
Expected: "\xEF\xBF\xBD"
Actual: "�"
2) Failure:
test_json_encode(OkJsonTest) [ok_json_test.rb:14]:
Expected: "{\"message\":\"á\"}"
Actual: "{\"message\":\"\\u00e1\"}"
3 tests, 3 assertions, 2 failures, 0 errors, 0 skips
~/Projects/opensource/jruby_report (master) $ ruby -v
ruby 1.9.3p125 (2012-02-16 revision 34643) [x86_64-darwin11.3.0]
Hey, no problem. That sounds about right. I've thought about this a few times before,
but it didn't seem like a big deal.
I just made kr/okjson#4 so I don't forget about this.