From bcfe49eb2f9e2424e0e2fddc3caa630eda1dde06 Mon Sep 17 00:00:00 2001 From: geekan Date: Fri, 7 Jul 2023 13:25:01 +0800 Subject: [PATCH] fix tests --- metagpt/const.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/metagpt/const.py b/metagpt/const.py index 0f51a6061..dcd36ad33 100644 --- a/metagpt/const.py +++ b/metagpt/const.py @@ -14,7 +14,7 @@ def get_project_root(): while True: if (current_path / '.git').exists() or \ (current_path / '.project_root').exists() or \ - (current_path.name.lower() == 'metagpt'): + (current_path.name.lower() == 'metagpt' and current_path.parent.name.lower() != 'tests'): return current_path parent_path = current_path.parent if parent_path == current_path: