Issue 14516: test_tools assumes BUILDDIR=SRCDIR (original) (raw)
When I run "make tests" I get (amongst others) the following test failure:
====================================================================== FAIL: test_noargs (test.test_tools.ReindentTests)
Traceback (most recent call last): File "/Users/ronald/Projects/python/rw/default/Lib/test/test_tools.py", line 30, in test_noargs assert_python_ok(self.script) File "/Users/ronald/Projects/python/rw/default/Lib/test/script_helper.py", line 53, in assert_python_ok return _assert_python(True, *args, **env_vars) File "/Users/ronald/Projects/python/rw/default/Lib/test/script_helper.py", line 45, in _assert_python "stderr follows:\n%s" % (rc, err.decode('ascii', 'ignore'))) AssertionError: Process return code is 2, stderr follows: /Users/ronald/Projects/python/rw/default/build/python.exe: can't open file '/Users/ronald/Projects/python/rw/default/build/Tools/scripts/reindent.py': [Errno 2] No such file or directory
This is because the script is actually "/Users/ronald/Projects/python/rw/default/Tools/scripts/reindent.py".
The attached patch fixes the issue.
(assigned to eric because he introduced these tests, unless there are objections I'll commit during the weekend)