Some test tuning.

This commit is contained in:
Jussi Pakkanen 2013-11-05 00:29:39 +02:00
parent bcdb84fcbe
commit 337b14e602
3 changed files with 15 additions and 1 deletions

View File

@ -419,7 +419,7 @@ class SharedLibrary(BuildTarget):
def __init__(self, name, subdir, is_cross, sources, objects, environment, kwargs):
self.version = None
self.soversion = None
super().__init__(name, subdir, is_cross, sources, environment, kwargs);
super().__init__(name, subdir, is_cross, sources, objects, environment, kwargs);
self.prefix = environment.get_shared_lib_prefix()
self.suffix = environment.get_shared_lib_suffix()

View File

@ -733,6 +733,9 @@ def find_cppcheck():
def is_osx():
return platform.system().lower() == 'darwin'
def is_linux():
return platform.system().lower() == 'linux'
def is_windows():
return platform.system().lower() == 'windows'

View File

@ -107,6 +107,12 @@ def gather_tests(testdir):
def run_tests():
commontests = gather_tests('test cases/common')
failtests = gather_tests('test cases/failing')
objtests = gather_tests('test cases/prebuilt object')
if environment.is_linux():
cpuid = platform.machine()
if cpuid != 'x86_64' and cpuid != 'i386':
# Don't have a prebuilt object file for those so skip.
objtests = []
if environment.is_osx():
platformtests = gather_tests('test cases/osx')
elif environment.is_windows():
@ -133,6 +139,11 @@ def run_tests():
[run_test(t) for t in commontests]
print('\nRunning failing tests.\n')
[run_test(t, False) for t in failtests]
if len(objtests) > 0:
print('\nRunning object inclusion tests.\n')
[run_test(t) for t in objtests]
else:
print('\nNo object inclusion tests.\n')
if len(platformtests) > 0:
print('\nRunning platform dependent tests.\n')
[run_test(t) for t in platformtests]