mirror of
https://github.com/pytorch/pytorch.git
synced 2025-10-20 21:14:14 +08:00
Summary: Action following https://github.com/pytorch/pytorch/issues/66232 Pull Request resolved: https://github.com/pytorch/pytorch/pull/66830 Reviewed By: albanD Differential Revision: D31905820 Pulled By: janeyx99 fbshipit-source-id: 9496acc98339d689fa62e18a8781d7344903a64c
17 lines
509 B
Python
17 lines
509 B
Python
# Owner(s): ["oncall: package/deploy"]
|
|
|
|
def load_tests(loader, standard_tests, pattern):
|
|
"""Load all tests from `test/pacakge/`
|
|
"""
|
|
if pattern is None:
|
|
# Use the default pattern if none is specified by the test loader.
|
|
pattern = "test*.py"
|
|
package_tests = loader.discover("package", pattern=pattern)
|
|
standard_tests.addTests(package_tests)
|
|
return standard_tests
|
|
|
|
|
|
if __name__ == "__main__":
|
|
from torch.testing._internal.common_utils import run_tests
|
|
run_tests()
|