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
Make the core testbase off-line ready #9324
Comments
Maybe https://pypi.org/project/pytest-httpbin/ (which AFAICT is not the actual httpbin)? |
we've added a flask testserver for python's azure-core tests. Most (but not all) tests are using this testserver. |
We are not 100% there yet. We still have streaming tests which rely on live storage account. |
Here's a file with the streaming tests that @xiangyan99 mentioned
|
…_no_header test in test_streaming.py by utilizing a new function I added in streams.py. This new test named test_compress_plain_no_header_offline, passes!
…s.py (Azure#21990) thank you to @emilychang9 !
…into add_back_error_message * 'main' of https://github.com/Azure/azure-sdk-for-python: switch error str tests to in (Azure#22016) drop py27 support (Azure#22531) Update TextAnalytics to enable live testing in sovereign clouds for multiple services (Azure#22461) fix: body is too long when create github release (Azure#22522) [AutoRelease] t2-labservices-2022-01-10-05622 (Azure#22401) [ACR] Change to support python3.6 or above only (Azure#22325) Sync eng/common directory with azure-sdk-tools for PR 2554 (Azure#22515) [purview catalog] regen with guids rest name fix (Azure#22495) Migrate EG tests to test proxy (Azure#21772) [Test Proxy] Normalize paths in test IDs (Azure#22508) Add packages to $PackageExclusions which do not build properly in Docs CI (Azure#22493) Update Manifest Publishing (Azure#22476) Issue Azure#9324 by DaisyCisneros (Azure#21824)
Tests that need to be made offline: test_streaming.py
test_streaming_async.py
|
@kristapratico I would love to take these up one by one(or all together depending on the requirement). I have already started and raised this PR : #33800 . I just need the reviewers feedback to make sure I am on the right track. If there is any feedback, I would be happy to incorporate it in my next revisions. |
Hey everyone .hope it is going well. I have updated #33800 to add all the test cases needed to be made offline. Currently all my changes are in a single PR. If you want me to break into multiple PR's for each test I can do that as well. If the code is not par or some case is missing. I would be happy to fix it. I would really really appreciate any response/feedback from your side. |
Hey everyone any feedback on the PR #33800 ?? |
@HimanshuBarak thanks for your patience. Review feedback was left on the PR. |
There is several tests that call httbin or bing, and they can't pass if there is no network. Need to find a way todo an actual HTTP request, with the less possible mock so we're confident it's working as expected.
I think I remember httpbin can be install locally, maybe that?
To investigate.
The text was updated successfully, but these errors were encountered: