Closed
Description
Describe the bug
Results don't always match the spec when using this gem with also the rails
gem loaded (more precisely: the activesupport
gem, which is a dependency of rails
).
This is because Rails overrides a number of to_json
methods and modifies them in a way that is incompatible, for example.
To reproduce
Steps to reproduce the behavior:
- Install and require this gem and
rails
"&".to_json_c14n
should give"&"
but instead gives"\u0026"
.
Expected behavior
This gem's behavior shouldn't depend on the presence of other gems, at least not ones as common as Rails.