aboutsummaryrefslogtreecommitdiff
path: root/run_tests.py
diff options
context:
space:
mode:
authorElliott Sales de Andrade <quantum.analyst@gmail.com>2017-06-14 05:09:42 -0400
committerJussi Pakkanen <jpakkane@gmail.com>2017-06-22 06:04:59 -0400
commita681348b057e3ef8df3d0e35fd146ec75a880b4a (patch)
tree8a4579c01429b12b03099a480bba1ebaf0f2d4d0 /run_tests.py
parent39c75d39fb2d8eb7b621c24d92357c5c761f869e (diff)
downloadmeson-a681348b057e3ef8df3d0e35fd146ec75a880b4a.zip
meson-a681348b057e3ef8df3d0e35fd146ec75a880b4a.tar.gz
meson-a681348b057e3ef8df3d0e35fd146ec75a880b4a.tar.bz2
Add some colour to test output.
Bold the section names and colourize errors&skips.
Diffstat (limited to 'run_tests.py')
-rwxr-xr-xrun_tests.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/run_tests.py b/run_tests.py
index 1549979..040f958 100755
--- a/run_tests.py
+++ b/run_tests.py
@@ -23,6 +23,7 @@ import tempfile
import platform
from mesonbuild import mesonlib
from mesonbuild import mesonmain
+from mesonbuild import mlog
from mesonbuild.environment import detect_ninja
from io import StringIO
from enum import Enum
@@ -177,7 +178,8 @@ if __name__ == '__main__':
if 'APPVEYOR' in os.environ and os.environ['arch'] == 'x86':
os.environ.pop('platform')
# Run tests
- print('Running unittests.\n')
+ print(mlog.bold('Running unittests.').get_text(mlog.colorize_console))
+ print()
units = ['InternalTests', 'AllPlatformTests', 'FailureTests']
if mesonlib.is_linux():
units += ['LinuxlikeTests']
@@ -200,7 +202,8 @@ if __name__ == '__main__':
returncode += subprocess.call([sys.executable, 'run_unittests.py', '-v'] + units, env=env)
# Ubuntu packages do not have a binary without -6 suffix.
if should_run_linux_cross_tests():
- print('Running cross compilation tests.\n')
+ print(mlog.bold('Running cross compilation tests.').get_text(mlog.colorize_console))
+ print()
returncode += subprocess.call([sys.executable, 'run_cross_test.py', 'cross/ubuntu-armhf.txt'], env=env)
returncode += subprocess.call([sys.executable, 'run_project_tests.py'] + sys.argv[1:], env=env)
sys.exit(returncode)