diff --git a/httprunner/loader/check.py b/httprunner/loader/check.py index 2f7720f4..5c0ca459 100644 --- a/httprunner/loader/check.py +++ b/httprunner/loader/check.py @@ -197,4 +197,8 @@ def is_testcase_path(path): if not os.path.exists(path): return False + file_suffix = os.path.splitext(path)[1].lower() + if file_suffix != ['.json', '.yaml', '.yml']: + return False + return True