aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2018-10-28 12:56:53 +0100
committerDavid Robillard <d@drobilla.net>2018-10-28 12:56:53 +0100
commit16e9e7ae64b9ce6cb39981c7cd77b3c4dc1b9f90 (patch)
treeced865b6744aa292c8a7558b05042da2623097cc
parenta71575babfe238bb8e750f26d2eae38580321ee6 (diff)
downloadserd-16e9e7ae64b9ce6cb39981c7cd77b3c4dc1b9f90.tar.gz
serd-16e9e7ae64b9ce6cb39981c7cd77b3c4dc1b9f90.tar.bz2
serd-16e9e7ae64b9ce6cb39981c7cd77b3c4dc1b9f90.zip
Use relative paths in test commands and output
-rw-r--r--wscript9
1 files changed, 5 insertions, 4 deletions
diff --git a/wscript b/wscript
index 92595f36..68d2e1ca 100644
--- a/wscript
+++ b/wscript
@@ -357,10 +357,11 @@ def test_suite(ctx, base_uri, testdir, report, isyntax, osyntax, options=''):
for (num, test) in enumerate(sorted(tests)):
action_node = model[test][mf + 'action'][0]
action = os.path.join('tests', testdir, os.path.basename(action_node))
+ rel_action = os.path.join(os.path.relpath(srcdir), action)
abs_action = os.path.join(srcdir, action)
uri = base_uri + os.path.basename(action)
- command = 'serdi_static %s -f "%s" "%s" > %s' % (
- options, abs_action, uri, action + '.out')
+ command = 'serdi_static %s -f %s "%s" > %s' % (
+ options, rel_action, uri, action + '.out')
# Run strict test
result = run_test(command, expected_return, action)
@@ -434,7 +435,7 @@ def test(ctx):
nul = os.devnull
autowaf.run_tests(ctx, APPNAME, [
- 'serdi_static "file://%s/tests/good/manifest.ttl" > %s' % (srcdir, nul),
+ 'serdi_static ../tests/good/manifest.ttl > %s' % nul,
'serdi_static -v > %s' % nul,
'serdi_static -h > %s' % nul,
'serdi_static -s "<foo> a <#Thingie> ." > %s' % nul,
@@ -442,7 +443,7 @@ def test(ctx):
], 0, name='serdi-cmd-good')
autowaf.run_tests(ctx, APPNAME, [
- 'serdi_static -q "file://%s/tests/bad/bad-id-clash.ttl" > %s' % (srcdir, nul),
+ 'serdi_static -q ../tests/bad/bad-id-clash.ttl > %s' % nul,
'serdi_static > %s' % nul,
'serdi_static ftp://example.org/unsupported.ttl > %s' % nul,
'serdi_static -i > %s' % nul,