diff options
| author | Jordan Cook <JWCook@users.noreply.github.com> | 2021-04-22 13:27:24 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-04-22 13:27:24 -0500 |
| commit | f2bf9bbfd8d711e9dfc8ccce83f439d765d484cb (patch) | |
| tree | fb617be7c7760390b7239899e6522d865956342f /tests/conftest.py | |
| parent | 38ddcf5425eadc6b174a8b053b2175c4dda00a1f (diff) | |
| parent | 3ec85f0107caedbe3b3bd8080bd3dac81b7baa17 (diff) | |
| download | requests-cache-f2bf9bbfd8d711e9dfc8ccce83f439d765d484cb.tar.gz | |
Merge pull request #242 from JWCook/integration-tests
Refactor backend integration tests
Diffstat (limited to 'tests/conftest.py')
| -rw-r--r-- | tests/conftest.py | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/tests/conftest.py b/tests/conftest.py index 577cb78..a918bc7 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -22,6 +22,13 @@ from timeout_decorator import timeout import requests_cache from requests_cache.session import ALL_METHODS, CachedSession +CACHE_NAME = 'pytest_cache' + +# Allow running longer stress tests with an environment variable +STRESS_TEST_MULTIPLIER = int(os.getenv('STRESS_TEST_MULTIPLIER', '1')) +N_THREADS = 2 * STRESS_TEST_MULTIPLIER +N_ITERATIONS = 4 * STRESS_TEST_MULTIPLIER + MOCKED_URL = 'http+mock://requests-cache.com/text' MOCKED_URL_HTTPS = 'https+mock://requests-cache.com/text' MOCKED_URL_JSON = 'http+mock://requests-cache.com/json' @@ -36,9 +43,10 @@ AWS_OPTIONS = { 'aws_secret_access_key': 'placeholder', } -# Configure logging to show debug output when tests fail (or with pytest -s) + +# Configure logging to show log output when tests fail (or with pytest -s) basicConfig(level='INFO') -getLogger('requests_cache').setLevel('DEBUG') +# getLogger('requests_cache').setLevel('DEBUG') logger = getLogger(__name__) |
