test runner for experiment.py

Summary: Add simple interactive testrunner for experiment.py

Reviewed By: shapovalov

Differential Revision: D35316221

fbshipit-source-id: d424bcba632eef89eefb56e18e536edb58ec6f85
This commit is contained in:
Jeremy Reizenstein
2022-05-26 05:33:03 -07:00
committed by Facebook GitHub Bot
parent fbd3c679ac
commit c31bf85a23
5 changed files with 453 additions and 4 deletions

View File

@@ -19,9 +19,9 @@ def interactive_testing_requested() -> bool:
"""
Certain tests are only useful when run interactively, and so are not regularly run.
These are activated by this funciton returning True, which the user requests by
setting the environment variable `PYTORCH3D_INTERACTIVE_TESTING`.
setting the environment variable `PYTORCH3D_INTERACTIVE_TESTING` to 1.
"""
return os.environ.get("PYTORCH3D_INTERACTIVE_TESTING", False)
return os.environ.get("PYTORCH3D_INTERACTIVE_TESTING", "") == "1"
def get_tests_dir() -> Path: