Merge "Add netopeer installation in fedora script"
[integration/test.git] / test / tools / odl-mdsal-clustering-tests / clustering-performance-test / create_plot_data_files.py
1 #!/usr/bin/python
2
3 text_file = open("out.log.txt", "r")
4 log = text_file.read()
5 text_file.close()
6
7 data = []
8
9 for line in log.splitlines():
10     if 'Total success rate: ' in line:
11         ll = line.split(',')
12         data.append(ll[0][24:])
13 print data
14
15 text_file = open("plot_data_create.txt", "w")
16 text_file.write('Rate_create\n')
17 text_file.write('{0}\n'.format(data[0]))
18 text_file.close()
19
20 text_file = open("plot_data_delete.txt", "w")
21 text_file.write('Rate_delete\n')
22 text_file.write('{0}\n'.format(data[1]))
23 text_file.close()