From f23287ff6bd5fbceca554b8473564dd9cf3ce96c Mon Sep 17 00:00:00 2001 From: David Robillard Date: Fri, 14 Apr 2017 10:42:59 +0200 Subject: Print consistent relative paths in test output --- wscript | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/wscript b/wscript index 3f12c150..738c66af 100644 --- a/wscript +++ b/wscript @@ -336,13 +336,15 @@ def test_manifest(ctx, srcdir, testdir, report, base_uri, isyntax, osyntax, test asserter = 'http://drobilla.net/drobilla#me' def run_test(action_node, expected_return): - output = os.path.join('tests', testdir, action_node + '.out') - action = os.path.join(srcdir, 'tests', testdir, action_node) - rel = os.path.relpath(action, os.path.join(srcdir, 'tests', testdir)) - command = 'serdi_static -i %s -o %s -f "%s" "%s" > %s' % ( - isyntax, osyntax, action, base_uri + rel, output) - - return autowaf.run_test(ctx, APPNAME, command, expected_return, name=str(action)) + action = os.path.join('tests', testdir, action_node) + output = os.path.join('tests', testdir, action_node + '.out') + abs_action = os.path.join(srcdir, action) + rel = os.path.relpath(abs_action, os.path.join(srcdir, 'tests', testdir)) + command = 'serdi_static -i %s -o %s -f "%s" "%s" > %s' % ( + isyntax, osyntax, abs_action, base_uri + rel, output) + + return autowaf.run_test(ctx, APPNAME, command, + expected_return, name=str(action)) def run_tests(test_class, expected_return, check_result=False): autowaf.begin_tests(ctx, APPNAME, str(test_class)) -- cgit v1.2.1