| Index: tools/deep_memory_profiler/PRESUBMIT.py
|
| diff --git a/tools/deep_memory_profiler/PRESUBMIT.py b/tools/deep_memory_profiler/PRESUBMIT.py
|
| index 88595b5d6affed3d60f99fec6e85107f75117dc1..965fad9beda64d2c7eac6f75bd1d6f9330e45f49 100644
|
| --- a/tools/deep_memory_profiler/PRESUBMIT.py
|
| +++ b/tools/deep_memory_profiler/PRESUBMIT.py
|
| @@ -10,8 +10,30 @@ details on the presubmit API built into gcl.
|
|
|
|
|
| def CommonChecks(input_api, output_api):
|
| + import sys
|
| + def join(*args):
|
| + return input_api.os_path.join(input_api.PresubmitLocalPath(), *args)
|
| +
|
| output = []
|
| - output.extend(input_api.canned_checks.RunPylint(input_api, output_api))
|
| + sys_path_backup = sys.path
|
| + try:
|
| + sys.path = [
|
| + join('..', 'find_runtime_symbols'),
|
| + ] + sys.path
|
| + output.extend(input_api.canned_checks.RunPylint(input_api, output_api))
|
| + finally:
|
| + sys.path = sys_path_backup
|
| +
|
| + output.extend(
|
| + input_api.canned_checks.RunUnitTestsInDirectory(
|
| + input_api, output_api,
|
| + input_api.os_path.join(input_api.PresubmitLocalPath(), 'tests'),
|
| + whitelist=[r'.+_test\.py$']))
|
| +
|
| + if input_api.is_committing:
|
| + output.extend(input_api.canned_checks.PanProjectChecks(input_api,
|
| + output_api,
|
| + owners_check=False))
|
| return output
|
|
|
|
|
|
|