Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix tests to be compatible with urllib3 2.0 #356

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

pquentin
Copy link
Contributor

Somehow some cassette files were incompatible. I also tried adding urllib3 2.0 tests in CI, let's see how that goes.

@pquentin
Copy link
Contributor Author

The urllib3 2.0 tests are fixed by urllib3/urllib3#2998

@sigmavirus24
Copy link
Collaborator

Is the company issue in the toolbelt or in betamax?

@pquentin
Copy link
Contributor Author

What is the company issue sorry? If you mean urllib3/urllib3#2999 it's a totally different issue

@sigmavirus24
Copy link
Collaborator

*compatibility

If rerecording the cassettes makes a difference it makes me think the compatibility problem is in Betamax fundamentally

@pquentin
Copy link
Contributor Author

Maybe it is. I don't know, I have to admit I stuck with the first thing that worked. But I did not have to change most responses, so this is definitely fishy. I would have to investigate more and understand how Betamax works.

@pquentin pquentin mentioned this pull request Apr 29, 2023
@kraj
Copy link

kraj commented Jul 13, 2023

patches from this pull are needed for tests to pass on master branch when using urllib3 2.0. I have a yocto setups and I can confirm the failures

==============================================================================================================
Failed test cases (sorted by testseries, ID)
==============================================================================================================
--------------------------------------------------------------------------------------------------------------
testseries | result_id : oeqa | runtime_meta-python-ptest-image-python3-requests-toolbelt_qemux86-64_20230713012809
    ptestresult.python3-requests-toolbelt.tests/test_dump.py::TestDumpRealResponses::test_dump_all
    ptestresult.python3-requests-toolbelt.tests/test_dump.py::TestDumpRealResponses::test_dump_response
    ptestresult.python3-requests-toolbelt.tests/test_sessions.py::TestBasedSession::test_prepared_request_override_base
    ptestresult.python3-requests-toolbelt.tests/test_sessions.py::TestBasedSession::test_prepared_request_with_base
    ptestresult.python3-requests-toolbelt.tests/test_sessions.py::TestBasedSession::test_request_override_base
    ptestresult.python3-requests-toolbelt.tests/test_sessions.py::TestBasedSession::test_request_with_base
--------------------------------------------------------------------------------------------------------------

without these patches.

@pquentin
Copy link
Contributor Author

Thanks for confirming! However I'm not sure the approach is correct and still works on 1.26.x. We would have to fix our CI to tell.

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.

3 participants