cdent / gabbi

Declarative HTTP Testing for Python and anything else
http://gabbi.readthedocs.org/
Other
148 stars 34 forks source link

Add yaml-based tests for host header and sni checking #310

Closed cdent closed 2 years ago

cdent commented 2 years ago

The addition of server_hostname to the httpclient PoolManager, without sufficient testing, has revealed some issues:

Tests are added here, and the minimum value for urllib3 will be set when a release is made.

Some of the tests are "live" meaning they require network, and can be skipped via the live test fixture if the GABBI_SKIP_NETWORK env variable is set to "true".

[1] https://github.com/urllib3/urllib3/issues/2534

Fixes #307 Fixes #309

cdent commented 2 years ago

Note that these tests are expected to fail until a new version of urllib3 becomes available after https://github.com/urllib3/urllib3/pull/2537 merges.

scottwallacesh commented 2 years ago

It appears https://github.com/urllib3/urllib3/issues/2534 is closed now. Will the tests now pass?

cdent commented 2 years ago

The issue is that there has not yet been a new release to pypi. I've inquired a few different times (and again today).

cdent commented 2 years ago

For historical reference: There was a 2.5.0 release, but I had to yank it as it failed to work properly with urllib3. The fix to urllib3 has not been released.

scottwallacesh commented 2 years ago

There was a new urllib3 release (v1.26.9) on the 16th! Your message must have prodded them.

cdent commented 2 years ago

There was a new urllib3 release (v1.26.9) on the 16th!

Yup, dealing with this is on my list for today. We should see a 2.5.1 release in the next few hours.

cdent commented 2 years ago

As a status update: I'm having some very bizarre test failures in py39-pytest, but not py39, which shouldn't be possible, but clearly they are happening. Still digging.

cdent commented 2 years ago

ooph, finally: https://pypi.org/project/gabbi/