diff options
Diffstat (limited to 'wscript')
-rw-r--r-- | wscript | 15 |
1 files changed, 15 insertions, 0 deletions
@@ -172,6 +172,7 @@ lib_source = ['src/base64.c', 'src/cursor.c', 'src/decimal.c', 'src/env.c', + 'src/filter.c', 'src/inserter.c', 'src/int_math.c', 'src/iter.c', @@ -676,6 +677,7 @@ def validation_test_suite(tst, def test(tst): + import subprocess import tempfile # Create test output directories @@ -756,6 +758,18 @@ def test(tst): check.file_equals('%s/tests/multifile/output.nq' % srcdir, 'tests/multifile/output.out.nq') + with tst.group('GrepCommand') as check: + with tempfile.TemporaryFile(mode='w+') as stdout: + cmd = _wrapped_command([ + serdi, + '-g', '?s <urn:example:p> <urn:example:o> .', + '-s', + '<urn:example:s> <urn:example:p> <urn:example:o> .\n' + '<urn:example:s> <urn:example:q> <urn:example:r> .\n']) + check(lambda: subprocess.check_output(cmd).decode('utf-8') == + '<urn:example:s> <urn:example:p> <urn:example:o> .\n', + name='wildcard subject') + with tst.group('BadCommands', expected=1, stderr=autowaf.NONEMPTY) as check: @@ -764,6 +778,7 @@ def test(tst): check([serdi, 'ftp://example.org/unsupported.ttl']) check([serdi, '-I']) check([serdi, '-c']) + check([serdi, '-g']) check([serdi, '-i', 'illegal']) check([serdi, '-i', 'turtle']) check([serdi, '-i']) |