Comments (6)
These are not fixtures. The test suite is incompatible with pytest, unfortunately.
from httpretty.
It woulkd be really good to have pytest support. */9 of my all packages with python modules supprts pytest.
[tkloczko@devel-g2v SPECS]$ grep ^%pytest python-* -l | wc -l; ls -1 python-* -l | wc -l
819
926
from httpretty.
Yeah, given how nosetests are completely broken with Python 3.11 (and we really don't want yet another patchset to fix them), I'm going to try to make a patch for this.
from httpretty.
Yay, I've found an easy way to fix that. It's not exactly the prettiest method but at least the patch is small.
from httpretty.
Tested that commit and indeed it fixes pytest 👍
Howevere there are still few pytest warnings 😋
+ PYTHONPATH=/home/tkloczko/rpmbuild/BUILDROOT/python-httpretty-1.1.4-8.fc35.x86_64/usr/lib64/python3.8/site-packages:/home/tkloczko/rpmbuild/BUILDROOT/python-httpretty-1.1.4-8.fc35.x86_64/usr/lib/python3.8/site-packages
+ /usr/bin/pytest -ra
=========================================================================== test session starts ============================================================================
platform linux -- Python 3.8.13, pytest-7.1.2, pluggy-1.0.0
rootdir: /home/tkloczko/rpmbuild/BUILD/HTTPretty-1.1.4
plugins: anyio-3.5.0, cov-3.0.0, mock-3.7.0
collected 11154 items
tests/bugfixes/nosetests/test_242_ssl_bad_handshake.py . [ 0%]
tests/bugfixes/nosetests/test_387_regex_port.py .. [ 0%]
tests/bugfixes/nosetests/test_388_unmocked_error_with_url.py . [ 0%]
tests/bugfixes/nosetests/test_413_regex.py .. [ 0%]
tests/bugfixes/nosetests/test_414_httpx.py . [ 0%]
tests/bugfixes/nosetests/test_416_boto3.py . [ 0%]
tests/bugfixes/nosetests/test_417_openssl.py .. [ 0%]
tests/bugfixes/nosetests/test_425_latest_requests.py . [ 0%]
tests/bugfixes/nosetests/test_430_respect_timeout.py . [ 0%]
tests/bugfixes/nosetests/test_eventlet.py . [ 0%]
tests/bugfixes/nosetests/test_redis.py s [ 0%]
tests/bugfixes/nosetests/test_tornado_bind_unused_port.py s [ 0%]
tests/bugfixes/pytest/test_426_mypy_segfault.py .................................................................................................................... [ 1%]
.................................................................................................................................................................... [ 2%]
.................................................................................................................................................................... [ 4%]
.................................................................................................................................................................... [ 5%]
.................................................................................................................................................................... [ 7%]
.................................................................................................................................................................... [ 8%]
.................................................................................................................................................................... [ 9%]
.................................................................................................................................................................... [ 11%]
.................................................................................................................................................................... [ 12%]
.................................................................................................................................................................... [ 14%]
.................................................................................................................................................................... [ 15%]
.................................................................................................................................................................... [ 17%]
.................................................................................................................................................................... [ 18%]
.................................................................................................................................................................... [ 20%]
.................................................................................................................................................................... [ 21%]
.................................................................................................................................................................... [ 23%]
.................................................................................................................................................................... [ 24%]
.................................................................................................................................................................... [ 26%]
.................................................................................................................................................................... [ 27%]
.................................................................................................................................................................... [ 29%]
.................................................................................................................................................................... [ 30%]
.................................................................................................................................................................... [ 32%]
.................................................................................................................................................................... [ 33%]
.................................................................................................................................................................... [ 34%]
.................................................................................................................................................................... [ 36%]
.................................................................................................................................................................... [ 37%]
.................................................................................................................................................................... [ 39%]
.................................................................................................................................................................... [ 40%]
.................................................................................................................................................................... [ 42%]
.................................................................................................................................................................... [ 43%]
.................................................................................................................................................................... [ 45%]
.................................................................................................................................................................... [ 46%]
.................................................................................................................................................................... [ 48%]
.................................................................................................................................................................... [ 49%]
.................................................................................................................................................................... [ 51%]
.................................................................................................................................................................... [ 52%]
.................................................................................................................................................................... [ 54%]
.................................................................................................................................................................... [ 55%]
.................................................................................................................................................................... [ 57%]
.................................................................................................................................................................... [ 58%]
.................................................................................................................................................................... [ 59%]
.................................................................................................................................................................... [ 61%]
.................................................................................................................................................................... [ 62%]
.................................................................................................................................................................... [ 64%]
.................................................................................................................................................................... [ 65%]
.................................................................................................................................................................... [ 67%]
.................................................................................................................................................................... [ 68%]
.................................................................................................................................................................... [ 70%]
.................................................................................................................................................................... [ 71%]
.................................................................................................................................................................... [ 73%]
.................................................................................................................................................................... [ 74%]
.................................................................................................................................................................... [ 76%]
.................................................................................................................................................................... [ 77%]
.................................................................................................................................................................... [ 79%]
.................................................................................................................................................................... [ 80%]
.................................................................................................................................................................... [ 82%]
.................................................................................................................................................................... [ 83%]
.................................................................................................................................................................... [ 84%]
.................................................................................................................................................................... [ 86%]
.................................................................................................................................................................... [ 87%]
.................................................................................................................................................................... [ 89%]
.................................................................................................................................................................... [ 90%]
.................................................................................................................................................................... [ 92%]
.................................................................................................................................................................... [ 93%]
.................................................................................................................................................................... [ 95%]
.................................................................................................................................................................... [ 96%]
.................................................................................................................................................................... [ 98%]
............................................................ [ 98%]
tests/functional/test_bypass.py ...... [ 98%]
tests/functional/test_debug.py sssss [ 98%]
tests/functional/test_decorator.py ...... [ 98%]
tests/functional/test_httplib2.py ............ [ 99%]
tests/functional/test_passthrough.py ss [ 99%]
tests/functional/test_requests.py .................................... [ 99%]
tests/functional/test_urllib2.py ............ [ 99%]
tests/pyopenssl/test_mock.py . [ 99%]
tests/unit/test_core.py .......................... [ 99%]
tests/unit/test_http.py . [ 99%]
tests/unit/test_httpretty.py ............................. [ 99%]
tests/unit/test_main.py ... [100%]
============================================================================= warnings summary =============================================================================
../../../../../usr/lib/python3.8/site-packages/eventlet/support/greenlets.py:6
/usr/lib/python3.8/site-packages/eventlet/support/greenlets.py:6: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.
preserves_excinfo = (distutils.version.LooseVersion(greenlet.__version__)
../../../../../usr/lib/python3.8/site-packages/eventlet/support/greenlets.py:7
/usr/lib/python3.8/site-packages/eventlet/support/greenlets.py:7: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.
>= distutils.version.LooseVersion('0.3.2'))
tests/bugfixes/nosetests/test_430_respect_timeout.py::test_read_timeout
/usr/lib/python3.8/site-packages/_pytest/threadexception.py:73: PytestUnhandledThreadExceptionWarning: Exception in thread Thread-18
Traceback (most recent call last):
File "/usr/lib64/python3.8/threading.py", line 932, in _bootstrap_inner
self.run()
File "/usr/lib64/python3.8/threading.py", line 870, in run
self._target(*self._args, **self._kwargs)
File "/home/tkloczko/rpmbuild/BUILDROOT/python-httpretty-1.1.4-8.fc35.x86_64/usr/lib/python3.8/site-packages/httpretty/core.py", line 1133, in fill_filekind
fk.write(utf8(item) + b'\n')
ValueError: write to closed file
warnings.warn(pytest.PytestUnhandledThreadExceptionWarning(msg))
tests/functional/test_urllib2.py::test_httpretty_should_allow_forcing_headers_urllib2
/home/tkloczko/rpmbuild/BUILDROOT/python-httpretty-1.1.4-8.fc35.x86_64/usr/lib/python3.8/site-packages/httpretty/core.py:1034: UserWarning: HTTPretty got to register the Content-Length header with "'35a'" which is not a number
warnings.warn(
-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
========================================================================= short test summary info ==========================================================================
SKIPPED [1] ../../../../../usr/lib/python3.8/site-packages/_pytest/unittest.py:364: no redis server available for test
SKIPPED [3] ../../../../../usr/lib/python3.8/site-packages/_pytest/unittest.py:364: Skipped
SKIPPED [5] ../../../../../usr/lib/python3.8/site-packages/_pytest/unittest.py:364: not currently supported
============================================================== 11145 passed, 9 skipped, 4 warnings in 59.56s ===============================================================
from httpretty.
Just retested in updated build env and now I have one unit failing
+ PYTHONPATH=/home/tkloczko/rpmbuild/BUILDROOT/python-httpretty-1.1.4-13.fc35.x86_64/usr/lib64/python3.8/site-packages:/home/tkloczko/rpmbuild/BUILDROOT/python-httpretty-1.1.4-13.fc35.x86_64/usr/lib/python3.8/site-packages
+ /usr/bin/pytest -ra -m 'not network'
==================================================================================== test session starts ====================================================================================
platform linux -- Python 3.8.16, pytest-7.2.0, pluggy-1.0.0
rootdir: /home/tkloczko/rpmbuild/BUILD/HTTPretty-1.1.4
plugins: anyio-3.6.2, cov-4.0.0, mock-3.10.0
collected 11154 items
tests/bugfixes/nosetests/test_242_ssl_bad_handshake.py . [ 0%]
tests/bugfixes/nosetests/test_387_regex_port.py .. [ 0%]
tests/bugfixes/nosetests/test_388_unmocked_error_with_url.py . [ 0%]
tests/bugfixes/nosetests/test_413_regex.py .. [ 0%]
tests/bugfixes/nosetests/test_414_httpx.py . [ 0%]
tests/bugfixes/nosetests/test_416_boto3.py . [ 0%]
tests/bugfixes/nosetests/test_417_openssl.py .. [ 0%]
tests/bugfixes/nosetests/test_425_latest_requests.py . [ 0%]
tests/bugfixes/nosetests/test_430_respect_timeout.py . [ 0%]
tests/bugfixes/nosetests/test_eventlet.py . [ 0%]
tests/bugfixes/nosetests/test_redis.py s [ 0%]
tests/bugfixes/nosetests/test_tornado_bind_unused_port.py s [ 0%]
tests/bugfixes/pytest/test_426_mypy_segfault.py ..................................................................................................................................... [ 1%]
..................................................................................................................................................................................... [ 2%]
..................................................................................................................................................................................... [ 4%]
..................................................................................................................................................................................... [ 6%]
..................................................................................................................................................................................... [ 7%]
..................................................................................................................................................................................... [ 9%]
..................................................................................................................................................................................... [ 11%]
..................................................................................................................................................................................... [ 12%]
..................................................................................................................................................................................... [ 14%]
..................................................................................................................................................................................... [ 15%]
..................................................................................................................................................................................... [ 17%]
..................................................................................................................................................................................... [ 19%]
..................................................................................................................................................................................... [ 20%]
..................................................................................................................................................................................... [ 22%]
..................................................................................................................................................................................... [ 24%]
..................................................................................................................................................................................... [ 25%]
..................................................................................................................................................................................... [ 27%]
..................................................................................................................................................................................... [ 28%]
..................................................................................................................................................................................... [ 30%]
..................................................................................................................................................................................... [ 32%]
..................................................................................................................................................................................... [ 33%]
..................................................................................................................................................................................... [ 35%]
..................................................................................................................................................................................... [ 37%]
..................................................................................................................................................................................... [ 38%]
..................................................................................................................................................................................... [ 40%]
..................................................................................................................................................................................... [ 41%]
..................................................................................................................................................................................... [ 43%]
..................................................................................................................................................................................... [ 45%]
..................................................................................................................................................................................... [ 46%]
..................................................................................................................................................................................... [ 48%]
..................................................................................................................................................................................... [ 50%]
..................................................................................................................................................................................... [ 51%]
..................................................................................................................................................................................... [ 53%]
..................................................................................................................................................................................... [ 54%]
..................................................................................................................................................................................... [ 56%]
..................................................................................................................................................................................... [ 58%]
..................................................................................................................................................................................... [ 59%]
..................................................................................................................................................................................... [ 61%]
..................................................................................................................................................................................... [ 62%]
..................................................................................................................................................................................... [ 64%]
..................................................................................................................................................................................... [ 66%]
..................................................................................................................................................................................... [ 67%]
..................................................................................................................................................................................... [ 69%]
..................................................................................................................................................................................... [ 71%]
..................................................................................................................................................................................... [ 72%]
..................................................................................................................................................................................... [ 74%]
..................................................................................................................................................................................... [ 75%]
..................................................................................................................................................................................... [ 77%]
..................................................................................................................................................................................... [ 79%]
..................................................................................................................................................................................... [ 80%]
..................................................................................................................................................................................... [ 82%]
..................................................................................................................................................................................... [ 84%]
..................................................................................................................................................................................... [ 85%]
..................................................................................................................................................................................... [ 87%]
..................................................................................................................................................................................... [ 88%]
..................................................................................................................................................................................... [ 90%]
..................................................................................................................................................................................... [ 92%]
..................................................................................................................................................................................... [ 93%]
..................................................................................................................................................................................... [ 95%]
..................................................................................................................................................................................... [ 97%]
..................................................................................................................................................................................... [ 98%]
....... [ 98%]
tests/functional/test_bypass.py ...... [ 98%]
tests/functional/test_debug.py sssss [ 98%]
tests/functional/test_decorator.py ...... [ 98%]
tests/functional/test_httplib2.py ............ [ 99%]
tests/functional/test_passthrough.py ss [ 99%]
tests/functional/test_requests.py ...................................F [ 99%]
tests/functional/test_urllib2.py ............ [ 99%]
tests/pyopenssl/test_mock.py . [ 99%]
tests/unit/test_core.py .......................... [ 99%]
tests/unit/test_http.py . [ 99%]
tests/unit/test_httpretty.py ............................. [ 99%]
tests/unit/test_main.py ... [100%]
========================================================================================= FAILURES ==========================================================================================
_______________________________________________________________ test_httpretty_should_handle_paths_starting_with_two_slashes ________________________________________________________________
self = <sure.AssertionBuilder object at 0x7f5f24f11d60>, args = ('//foo',), kw = {}
@wraps(func)
def wrapper(self, *args, **kw):
try:
> value = func(self, *args, **kw)
/usr/lib/python3.8/site-packages/sure/__init__.py:408:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <sure.AssertionBuilder object at 0x7f5f24f11d60>, what = '//foo', epsilon = None
@assertionmethod
def equal(self, what, epsilon=None):
"""compares given object ``X`` with an expected ``Y`` object.
It primarily assures that the compared objects are absolute equal ``==``.
:param what: the expected value
:param epsilon: a delta to leverage upper-bound floating point permissiveness
"""
try:
comparison = DeepComparison(self.obj, what, epsilon).compare()
error = False
except AssertionError as e:
error = e
comparison = None
if isinstance(comparison, DeepExplanation):
error = comparison.get_assertion(self.obj, what)
if self.negative:
if error:
return True
msg = "%s should differ from %s, but is the same thing"
raise AssertionError(msg % (safe_repr(self.obj), safe_repr(what)))
else:
if not error:
return True
> raise error
/usr/lib/python3.8/site-packages/sure/__init__.py:729:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <sure.AssertionBuilder object at 0x7f5f24f11d60>, what = '//foo', epsilon = None
@assertionmethod
def equal(self, what, epsilon=None):
"""compares given object ``X`` with an expected ``Y`` object.
It primarily assures that the compared objects are absolute equal ``==``.
:param what: the expected value
:param epsilon: a delta to leverage upper-bound floating point permissiveness
"""
try:
> comparison = DeepComparison(self.obj, what, epsilon).compare()
/usr/lib/python3.8/site-packages/sure/__init__.py:710:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <sure.core.DeepComparison object at 0x7f5f2404a1f0>
def compare(self):
X, Y = self.operands
if isinstance(X, _CallList):
X = list(X)
if isinstance(Y, _CallList):
X = list(Y)
c = self.get_context()
if self.is_complex(X) and type(X) is type(Y):
return self.compare_complex_stuff(X, Y)
def safe_format_repr(string):
"Escape '{' and '}' in string for use with str.format()"
if not isinstance(string, (string_types, binary_type)):
return string
orig_str_type = type(string)
if isinstance(string, binary_type):
safe_repr = string.replace(b'{', b'{{').replace(b'}', b'}}')
else:
safe_repr = string.replace('{', '{{').replace('}', '}}')
# NOTE: str.replace() automatically converted the 'string' to 'unicode' in Python 2
return orig_str_type(safe_repr)
# get safe representation for X and Y
safe_X, safe_Y = safe_format_repr(X), safe_format_repr(Y)
# maintaining backwards compatibility between error messages
kwargs = {}
if self.is_simple(X) and self.is_simple(Y):
kwargs['msg_format'] = 'X{{0}} is {0!r} whereas Y{{1}} is {1!r}'.format(safe_X, safe_Y)
elif type(X) is not type(Y):
kwargs['msg_format'] = 'X{{0}} is a {0} and Y{{1}} is a {1} instead'.format(
type(X).__name__, type(Y).__name__)
exp = self.compare_generic(X, Y, **kwargs)
if isinstance(exp, DeepExplanation):
original_X, original_Y = c.parent.operands
> raise exp.as_assertion(original_X, original_Y)
/usr/lib/python3.8/site-packages/sure/core.py:254:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = "X is '/foo' whereas Y is '//foo'", X = '/foo', Y = '//foo'
def as_assertion(self, X, Y):
> raise self.get_assertion(X, Y)
E AssertionError: given
E X = '/foo'
E and
E Y = '//foo'
E X is '/foo' whereas Y is '//foo'
/usr/lib/python3.8/site-packages/sure/core.py:57: AssertionError
During handling of the above exception, another exception occurred:
@httprettified
def test_httpretty_should_handle_paths_starting_with_two_slashes():
"HTTPretty should handle URLs with paths starting with //"
HTTPretty.register_uri(
HTTPretty.GET, "http://example.com//foo",
body="Find the best foo"
)
response = requests.get('http://example.com//foo')
expect(response.text).to.equal('Find the best foo')
expect(HTTPretty.last_request.method).to.equal('GET')
> expect(HTTPretty.last_request.path).to.equal('//foo')
tests/functional/test_requests.py:949:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <sure.AssertionBuilder object at 0x7f5f24f11d60>, args = ('//foo',), kw = {}
@wraps(func)
def wrapper(self, *args, **kw):
try:
value = func(self, *args, **kw)
except AssertionError as e:
> raise AssertionError(e)
E AssertionError: given
E X = '/foo'
E and
E Y = '//foo'
E X is '/foo' whereas Y is '//foo'
/usr/lib/python3.8/site-packages/sure/__init__.py:410: AssertionError
===================================================================================== warnings summary ======================================================================================
../../BUILDROOT/python-httpretty-1.1.4-13.fc35.x86_64/usr/lib/python3.8/site-packages/httpretty/core.py:176
/home/tkloczko/rpmbuild/BUILDROOT/python-httpretty-1.1.4-13.fc35.x86_64/usr/lib/python3.8/site-packages/httpretty/core.py:176: DeprecationWarning: 'urllib3.contrib.pyopenssl' module is deprecated and will be removed in a future release of urllib3 2.x. Read more in this issue: https://github.com/urllib3/urllib3/issues/2680
from requests.packages.urllib3.contrib.pyopenssl import inject_into_urllib3, extract_from_urllib3
../../BUILDROOT/python-httpretty-1.1.4-13.fc35.x86_64/usr/lib/python3.8/site-packages/httpretty/core.py:185
/home/tkloczko/rpmbuild/BUILDROOT/python-httpretty-1.1.4-13.fc35.x86_64/usr/lib/python3.8/site-packages/httpretty/core.py:185: DeprecationWarning: 'urllib3.contrib.pyopenssl' module is deprecated and will be removed in a future release of urllib3 2.x. Read more in this issue: https://github.com/urllib3/urllib3/issues/2680
from urllib3.contrib.pyopenssl import extract_from_urllib3, inject_into_urllib3
../../../../../usr/lib/python3.8/site-packages/eventlet/support/greenlets.py:6
/usr/lib/python3.8/site-packages/eventlet/support/greenlets.py:6: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.
preserves_excinfo = (distutils.version.LooseVersion(greenlet.__version__)
../../../../../usr/lib/python3.8/site-packages/eventlet/support/greenlets.py:7
/usr/lib/python3.8/site-packages/eventlet/support/greenlets.py:7: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.
>= distutils.version.LooseVersion('0.3.2'))
tests/bugfixes/nosetests/test_430_respect_timeout.py::test_read_timeout
/usr/lib/python3.8/site-packages/_pytest/threadexception.py:73: PytestUnhandledThreadExceptionWarning: Exception in thread Thread-18
Traceback (most recent call last):
File "/usr/lib64/python3.8/threading.py", line 932, in _bootstrap_inner
self.run()
File "/usr/lib64/python3.8/threading.py", line 870, in run
self._target(*self._args, **self._kwargs)
File "/home/tkloczko/rpmbuild/BUILDROOT/python-httpretty-1.1.4-13.fc35.x86_64/usr/lib/python3.8/site-packages/httpretty/core.py", line 1133, in fill_filekind
fk.write(utf8(item) + b'\n')
ValueError: write to closed file
warnings.warn(pytest.PytestUnhandledThreadExceptionWarning(msg))
tests/functional/test_requests.py::test_recording_calls
/usr/lib64/python3.8/site-packages/tornado/ioloop.py:350: DeprecationWarning: make_current is deprecated; start the event loop first
self.make_current()
tests/functional/test_urllib2.py::test_httpretty_should_allow_forcing_headers_urllib2
/home/tkloczko/rpmbuild/BUILDROOT/python-httpretty-1.1.4-13.fc35.x86_64/usr/lib/python3.8/site-packages/httpretty/core.py:1034: UserWarning: HTTPretty got to register the Content-Length header with "'35a'" which is not a number
warnings.warn(
-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
================================================================================== short test summary info ==================================================================================
SKIPPED [1] ../../../../../usr/lib/python3.8/site-packages/_pytest/unittest.py:367: no redis server available for test
SKIPPED [3] ../../../../../usr/lib/python3.8/site-packages/_pytest/unittest.py:367: Skipped
SKIPPED [5] ../../../../../usr/lib/python3.8/site-packages/_pytest/unittest.py:367: not currently supported
FAILED tests/functional/test_requests.py::test_httpretty_should_handle_paths_starting_with_two_slashes - AssertionError: given
================================================================== 1 failed, 11144 passed, 9 skipped, 7 warnings in 23.97s ==================================================================
Here is list of installed modules in build env
Package Version
----------------------------- -----------------
alabaster 0.7.12
anyio 3.6.2
async-timeout 4.0.2
attrs 22.2.0
Babel 2.11.0
boto3 1.26.49
botocore 1.29.49
build 0.9.0
certifi 2022.9.24
cffi 1.15.1
charset-normalizer 3.0.1
coverage 7.0.3
cryptography 38.0.4
distro 1.8.0
dnspython 2.2.1
docutils 0.19
eventlet 0.33.1
exceptiongroup 1.0.0
extras 1.0.0
fixtures 4.0.0
freezegun 1.2.1
gpg 1.18.0-unknown
greenlet 1.1.3
h11 0.13.0
httpcore 0.16.3
httplib2 0.20.4
httpx 0.23.3
idna 3.4
imagesize 1.4.1
importlib-metadata 5.1.0
iniconfig 1.1.1
Jinja2 3.1.2
jmespath 1.0.0
libcomps 0.1.19
MarkupSafe 2.1.1
mock 4.0.3
packaging 21.3
pbr 5.9.0
pep517 0.13.0
pip 22.3.1
pluggy 1.0.0
ply 3.11
pycparser 2.21
Pygments 2.14.0
PyGObject 3.42.2
pyOpenSSL 22.0.0
pyparsing 3.0.9
pytest 7.2.0
pytest-cov 4.0.0
pytest-mock 3.10.0
python-dateutil 2.8.2
pytz 2022.4
redis 4.4.0
requests 2.28.1
rpm 4.17.0
s3transfer 0.6.0
setuptools 65.6.3
six 1.16.0
sniffio 1.2.0
snowballstemmer 2.2.0
Sphinx 5.3.0
sphinx-rtd-theme 1.1.1
sphinxcontrib-applehelp 1.0.2.dev20221204
sphinxcontrib.asciinema 0.3.3
sphinxcontrib-devhelp 1.0.2.dev20221204
sphinxcontrib-htmlhelp 2.0.0
sphinxcontrib-jsmath 1.0.1.dev20221204
sphinxcontrib-qthelp 1.0.3.dev20221204
sphinxcontrib-serializinghtml 1.1.5
sure 2.0.0
testtools 2.5.0
tomli 2.0.1
tornado 6.2
urllib3 1.26.12
wheel 0.38.4
zipp 3.11.0
from httpretty.
Related Issues (20)
- Dependency Dashboard
- Action Required: Fix Renovate Configuration
- Emulate server down then coming online HOT 1
- Incorrect examples in documentation (contextmanager) HOT 2
- httpretty.errors.UnmockedError: Failed to socket.setblocking because because a real socket does not exist HOT 1
- 1.1.4: sphinx warnings `reference target not found`
- Typing error when using callback as body
- State of project HOT 1
- test_httpretty_should_handle_paths_starting_with_two_slashes needs update HOT 2
- 1.1.4: Tests are failing on s390x because of "did not run within two miliseconds" HOT 1
- Document global allow_net_connect flag HOT 1
- Request body isn't decoded when client specifies its charset
- Link headers Example does not work
- Reset should blank latest_requests? HOT 1
- FakeSockFile: `'super' object has no attribute 'flush'` HOT 1
- urllib3.contrib.pyopenssl is being deprecated
- Requests upgrade to v2.29.0 causes the test case test_httpretty_should_allow_registering_regexes_with_streaming_responses to fail
- Why httpretty.enabled(context manager) effect is getting reset after it encounter @httpretty.activate ? HOT 1
- Long response time when calling unmatched requests
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from httpretty.