Skip to content

Fixing tests#96

Closed
softwaregravy wants to merge 2 commits intojanko:masterfrom
softwaregravy:93_tests
Closed

Fixing tests#96
softwaregravy wants to merge 2 commits intojanko:masterfrom
softwaregravy:93_tests

Conversation

@softwaregravy
Copy link
Contributor

For issue #93

Effectively, we're changing the text to match the output which on principle is not great. I think maybe matching the text of inspect is brittle and these tests need a re-think.

The text change on encoding I believe came from this change. So this does not pass on ruby 3.3.6, but does pass on 3.4.1 (not sure exactly which release that change came out in).

Partial fix for janko#93
This may not be the 'correct' fix, but it will not break any current
users and is safe for immediate release
@janko
Copy link
Owner

janko commented Feb 1, 2025

Thanks for the heads-up. I think we can just call Encoing::BINARY.inspect in tests, that way it will work both in Ruby 3.4 and earlier. I'll push a change for this shortly.

@janko janko closed this in 2a7a4e3 Feb 1, 2025
@softwaregravy
Copy link
Contributor Author

@janko yours is definitely the better solution.

Note the similar problem in the httpx_test not covered by your change.

@janko
Copy link
Owner

janko commented Feb 1, 2025

Thanks, I missed it. That one doesn't appear Ruby 3.4-related, but just a newer version of HTTPX, I pushed an update now as well.

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