blob: e5e11e9ff520b3304b3c447f4df3a74f9c67f72d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
|
#!/usr/bin/env python
##############################################################################
# Copyright (c) 2016 Huawei Technologies Co.,Ltd and others.
#
# All rights reserved. This program and the accompanying materials
# are made available under the terms of the Apache License, Version 2.0
# which accompanies this distribution, and is available at
# http://www.apache.org/licenses/LICENSE-2.0
##############################################################################
import sys
import subprocess
INTERPRETER = "/usr/bin/python"
# ------------------------------------------------------
# run posca testcase
# ------------------------------------------------------
def posca_run(arg):
print("========== run posca ==========")
print(arg)
if(arg == "posca_factor_system_bandwidth"):
print("========== run posca_system_bandwidth ===========")
cmd = '/home/opnfv/bottlenecks/testsuites/posca/testcase_script/\
posca_factor_system_bandwidth.py'
pargs = [INTERPRETER, cmd]
sub_result = subprocess.Popen(pargs)
sub_result.wait()
def posca_env_check():
print("========== posca env check ===========")
def main():
# para_testname = sys.argv[0]
para_test_arg = sys.argv[2]
posca_env_check()
posca_run(para_test_arg)
sys.exit(0)
if __name__ == '__main__':
main()
|