Prevent test manifests from being run

The test runner was running the manifest and other crap files. Now it
filters out to just the executables.

Signed-off-by: Vicent Marti <tanoku@gmail.com>
This commit is contained in:
Vicent Marti 2010-12-23 01:00:40 +02:00
parent e6c8966d37
commit 51035184dd

View File

@ -209,12 +209,15 @@ class _run_tests(Context):
fun = 'run_tests' fun = 'run_tests'
def run_tests(ctx): def run_tests(ctx):
import shutil, tempfile import shutil, tempfile, sys
failed = False failed = False
test_folder = tempfile.mkdtemp() test_folder = tempfile.mkdtemp()
test_glob = 'build/tests/t????-*' test_glob = 'build/tests/t????-*'
if sys.platform == 'win32':
test_glob += '.exe'
for test in ctx.path.ant_glob(test_glob): for test in ctx.path.ant_glob(test_glob):
if ctx.exec_command(test.abspath(), cwd=test_folder) != 0: if ctx.exec_command(test.abspath(), cwd=test_folder) != 0:
failed = True failed = True