Add concurrency support in new integration tests
Add support of parallel running tests. Testr provide ability to setting number of processes for running tests. By default concurrency = <num_of_cores_in_cpu> partially implements bp: scenario-integration-tests Change-Id: Iebe570382e463b485fbcb57608c3d6d82690e098
This commit is contained in:
parent
bc911a3acb
commit
720a87ff60
|
@ -1,3 +1,5 @@
|
|||
concurrency: 1
|
||||
|
||||
credentials:
|
||||
os_username: admin
|
||||
os_password: nova
|
||||
|
|
|
@ -92,8 +92,12 @@ def main():
|
|||
path=test_dir_path)
|
||||
|
||||
# run tests
|
||||
concurrency = config.get('concurrency')
|
||||
os.environ['DISCOVER_DIRECTORY'] = test_dir_path
|
||||
return_code = os.system('bash tools/pretty_tox.sh')
|
||||
command = 'bash tools/pretty_tox.sh'
|
||||
if concurrency:
|
||||
command = command + ' -- --concurrency %d' % concurrency
|
||||
return_code = os.system(command)
|
||||
sys.exit(return_code)
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue