Skip to content

Backport JSONCommonInterfaceTest#test_unsafe_load_default_options#851

Merged
byroot merged 1 commit into
masterfrom
fix-flaky-test
Sep 8, 2025
Merged

Backport JSONCommonInterfaceTest#test_unsafe_load_default_options#851
byroot merged 1 commit into
masterfrom
fix-flaky-test

Conversation

@hsbt

@hsbt hsbt commented Sep 5, 2025

Copy link
Copy Markdown
Member

JSONCommonInterfaceTest#test_unsafe_load_default_options is failed with the following:

  1) Failure:
JSONCommonInterfaceTest#test_unsafe_load_default_options [/path/to/ruby/test/json/json_common_interface_test.rb:230]:
<2025-09-03 14:28:31.293635 +0200> expected but was
<"2025-09-03 14:28:31 +0200">.

I'm not sure why that test is different result with only head version of ruby. I fixed the Time object and convert to String for assertion.

JSON.unsafe_load with Time object returns String

```
  1) Failure:
JSONCommonInterfaceTest#test_unsafe_load_default_options [/path/to/ruby/test/json/json_common_interface_test.rb:230]:
<2025-09-03 14:28:31.293635 +0200> expected but was
<"2025-09-03 14:28:31 +0200">.
```
@byroot byroot merged commit 8f90de7 into master Sep 8, 2025
70 checks passed
@byroot byroot deleted the fix-flaky-test branch September 8, 2025 07:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants