def get_config_cmd(build_device):
packages=['bsdtar', 'psmisc', 'wget', 'python3', 'python3-pip', \
'libglib2.0-dev', 'libffi-dev', 'elfutils', 'libdw-dev', \
- 'libelf-dev', 'libmount-dev', 'libxml2', 'libpfm4-dev']
+ 'libelf-dev', 'libmount-dev', 'libxml2', 'libpfm4-dev', \
+ 'libnuma-dev']
command = OrderedDict({
'command': 'lava_command_run',
'parameters': {
'cat /etc/resolv.conf',
'echo nameserver 172.18.0.12 > /etc/resolv.conf',
'groupadd tracing'
- ]
+ ],
+ 'timeout':300
}
})
if build_device in 'x86':
lava_api_key = None
try:
- lava_api_key = os.environ['LAVA_FRDESO_TOKEN']
+ lava_api_key = os.environ['LAVA_JENKINS_TOKEN']
except Exception as e:
- print('LAVA_FRDESO_TOKEN not found in the environment variable. Exiting...', e )
+ print('LAVA_JENKINS_TOKEN not found in the environment variable. Exiting...', e )
return -1
if test_type is TestType.baremetal_benchmarks:
jobid = server.scheduler.submit_job(json.dumps(j))
print('Lava jobid:{}'.format(jobid))
+ print('Lava job URL: http://lava-master.internal.efficios.com/scheduler/job/{}/log_file'.format(jobid))
#Check the status of the job every 30 seconds
jobstatus = server.scheduler.job_status(jobid)['job_status']
time.sleep(30)
jobstatus = server.scheduler.job_status(jobid)['job_status']
- passed, failed=check_job_all_test_cases_state_count(server, jobid)
-
if test_type is TestType.kvm_tests or test_type is TestType.baremetal_tests:
print_test_output(server, jobid)
elif test_type is TestType.baremetal_benchmarks:
if jobstatus not in 'Complete':
return -1
else:
+ passed, failed=check_job_all_test_cases_state_count(server, jobid)
print('With {} passed and {} failed Lava test cases.'.format(passed, failed))
- if failed == 0:
- return 0
- else:
- return -1
+ if failed == 0:
+ return 0
+ else:
+ return -1
if __name__ == "__main__":
sys.exit(main())