ruby/test/json
Jean Boussier 0d62037fc0
[ruby/json] Ensure parser error snippets are valid UTF-8
Fix: https://github.com/ruby/json/issues/755

Error messages now include a snippet of the document
that doesn't parse to help locate the issue, however
the way it was done wasn't UTF-8 aware, and it could
result in exception messages with truncated characters.

It would be nice to go a bit farther and actually support
codepoints, but it's a lot of complexity to do it in C,
perhaps if we move that logic to Ruby given it's not a
performance sensitive codepath.

e144793b72
2025-02-27 13:32:32 +09:00
..
fixtures [ruby/json] Resync 2024-11-05 18:00:36 +01:00
json_addition_test.rb [ruby/json] Categorize deprecated warning 2024-11-06 23:31:30 +01:00
json_coder_test.rb Fix JSON::Coder to call as_json proc for NaN and Infinity 2025-02-06 16:02:03 +09:00
json_common_interface_test.rb [ruby/json] JSON.dump: write directly into the provided IO 2024-11-26 15:11:05 +09:00
json_encoding_test.rb Use frozen string literals 2024-10-26 18:44:15 +09:00
json_ext_parser_test.rb [ruby/json] Refactor JSON::Ext::Parser to split configuration and parsing state 2025-01-14 09:08:02 +01:00
json_fixtures_test.rb [ruby/json] Refactor JSONFixturesTest 2025-01-16 09:01:11 +09:00
json_generator_test.rb Fix a compatibility issue with MultiJson.dump(obj, pretty: true) 2025-02-12 13:15:01 +09:00
json_generic_object_test.rb Refactor to omit JSON::GenericObject tests 2025-01-08 17:12:19 +09:00
json_parser_test.rb [ruby/json] Ensure parser error snippets are valid UTF-8 2025-02-27 13:32:32 +09:00
json_string_matching_test.rb Use frozen string literals 2024-10-26 18:44:15 +09:00
ractor_test.rb json_pure: fix ractor compatibility 2024-10-26 18:44:15 +09:00
test_helper.rb [ruby/json] Appease ruby/ruby CI 2024-11-05 18:00:36 +01:00