From 80a97d01ba21df6d06ca750789bfe0bbacaaee4a Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Wed, 20 Apr 2022 20:49:04 +0200 Subject: Allow tests to be run on Windows. --- cscript | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'cscript') diff --git a/cscript b/cscript index 7b767ddf..fd625204 100644 --- a/cscript +++ b/cscript @@ -52,7 +52,7 @@ def build(target, options): # We only build tests on Ubuntu 18.04 cmd += ' --disable-tests' elif target.platform == 'windows': - cmd += f' --target-windows-{target.bits} --disable-tests' + cmd += f' --target-windows-{target.bits}' if target.version == 'xp': # OpenJPEG 1.x is inexplicably faster on Windows XP; see DCP-o-matic bug #771 cmd += ' --jpeg=oj1' @@ -89,9 +89,9 @@ def make_doxygen(target): return os.path.abspath('build/doc/html') def test(target, test): - if target.platform != 'windows': - target.set('LC_ALL', 'C') - if test is None: - target.command('run/tests') - else: - target.command('run/tests --run_test=%s' % test) + target.set('LC_ALL', 'C') + cmd = 'run\\tests ' if target.platform == 'windows' else 'run/tests ' + if test is not None: + cmd += '-t %s' % test + target.command(cmd) + -- cgit v1.2.3