From 587ba7cd5f448337cda468fbeeb3f9fcaec80057 Mon Sep 17 00:00:00 2001 From: "Unknown W. Brackets" Date: Sun, 3 Nov 2013 00:13:33 -0700 Subject: [PATCH] Allow test.py to run from within a build/ dir. --- test.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/test.py b/test.py index 9ef9c7fd41..d2b11c3c04 100755 --- a/test.py +++ b/test.py @@ -282,10 +282,13 @@ tests_ignored = [ def init(): - global PPSSPP_EXE + global PPSSPP_EXE, TEST_ROOT if not os.path.exists("pspautotests"): - print("Please run git submodule init; git submodule update;") - sys.exit(1) + if os.path.exists(os.path.dirname(__file__) + "/pspautotests"): + TEST_ROOT = os.path.dirname(__file__) + "/pspautotests/tests/"; + else: + print("Please run git submodule init; git submodule update;") + sys.exit(1) if not os.path.exists(TEST_ROOT + "cpu/cpu_alu/cpu_alu.prx"): print("Please install the pspsdk and run make in common/ and in all the tests")