diff --git a/setup.cfg b/setup.cfg index fbbc3e200..96308d00b 100644 --- a/setup.cfg +++ b/setup.cfg @@ -16,4 +16,19 @@ profile = black combine_as_imports = True [tool:pytest] -addopts = --cov-report= --cov=starlette --cov=tests -rxXs +addopts = + --cov-report=term-missing:skip-covered + --cov=starlette + --cov=tests + -rxXs + --strict-config + --strict-markers + --cov-config tests/.ignore_lifespan + --cov-fail-under=100 +xfail_strict=True +filterwarnings= + error + ignore: "@coroutine" decorator is deprecated.*:DeprecationWarning + ignore: Using or importing the ABCs from 'collections' instead of from 'collections\.abc' is deprecated.*:DeprecationWarning + ignore: The 'context' alias has been deprecated. Please use 'context_value' instead\.:DeprecationWarning + ignore: The 'variables' alias has been deprecated. Please use 'variable_values' instead\.:DeprecationWarning diff --git a/tests/test_datastructures.py b/tests/test_datastructures.py index 87a796787..b2b3c97ae 100644 --- a/tests/test_datastructures.py +++ b/tests/test_datastructures.py @@ -213,13 +213,13 @@ def test_queryparams(): assert QueryParams(q) == q -class TestUploadFile(UploadFile): +class _TestUploadFile(UploadFile): spool_max_size = 1024 @pytest.mark.asyncio async def test_upload_file(): - big_file = TestUploadFile("big-file") + big_file = _TestUploadFile("big-file") await big_file.write(b"big-data" * 512) await big_file.write(b"big-data") await big_file.seek(0)