[7.x] Remove yarl from [async] extra

Co-authored-by: Seth Michael Larson <[email protected]>
This commit is contained in:
github-actions[bot]
2020-10-13 15:18:07 -05:00
committed by GitHub
co-authored by Seth Michael Larson
parent 9b8cee0199
commit 0cdeeb654a
5 changed files with 49 additions and 13 deletions
@@ -41,3 +41,16 @@ class TestBulk:
assert response["errors"] is False
assert len(response["items"]) == 1
class TestYarlMissing:
async def test_aiohttp_connection_works_without_yarl(
self, async_client, monkeypatch
):
# This is a defensive test case for if aiohttp suddenly stops using yarl.
from elasticsearch._async import http_aiohttp
monkeypatch.setattr(http_aiohttp, "yarl", False)
resp = await async_client.info(pretty=True)
assert isinstance(resp, dict)