summaryrefslogtreecommitdiff
path: root/numpy/typing/tests/test_typing.py
diff options
context:
space:
mode:
authorMatti Picus <matti.picus@gmail.com>2021-02-24 18:03:05 +0200
committerGitHub <noreply@github.com>2021-02-24 18:03:05 +0200
commit98cb6bc8522b89ef308da40a26fa910fd1a17097 (patch)
tree2654f8b12c99be7cb4c290cb063619a69b076347 /numpy/typing/tests/test_typing.py
parentb51b540285d4cf2af69976c1e3b285f7c21b46f7 (diff)
parentd4c123657f08b43939a7b7e329f40015d38b2849 (diff)
downloadnumpy-98cb6bc8522b89ef308da40a26fa910fd1a17097.tar.gz
Merge pull request #18433 from bashtage/randomstate-typing
ENH: Add typing for RandomState
Diffstat (limited to 'numpy/typing/tests/test_typing.py')
-rw-r--r--numpy/typing/tests/test_typing.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/numpy/typing/tests/test_typing.py b/numpy/typing/tests/test_typing.py
index e80282420..70355dcd9 100644
--- a/numpy/typing/tests/test_typing.py
+++ b/numpy/typing/tests/test_typing.py
@@ -48,8 +48,11 @@ def run_mypy() -> None:
The mypy results are cached in `OUTPUT_MYPY` for further use.
+ The cache refresh can be skipped using
+
+ NUMPY_TYPING_TEST_CLEAR_CACHE=0 pytest numpy/typing/tests
"""
- if os.path.isdir(CACHE_DIR):
+ if os.path.isdir(CACHE_DIR) and bool(os.environ.get("NUMPY_TYPING_TEST_CLEAR_CACHE", True)):
shutil.rmtree(CACHE_DIR)
for directory in (PASS_DIR, REVEAL_DIR, FAIL_DIR, MISC_DIR):