Blazemeter / taurus
Showing 1 of 2 files from the diff.
Other files ignored by Codecov

@@ -105,28 +105,36 @@
Loading
105 105
        self.data = {'timestamp': [], 'label': [], 'r_code': [], 'error_msg': [], 'http_req_duration': [],
106 106
                     'http_req_connecting': [], 'http_req_tls_handshaking': [], 'http_req_waiting': [], 'vus': [],
107 107
                     'data_received': []}
108 +
        self.position = {'timestamp': None, 'metric_value': None, 'error': None, 'name': None, 'status': None}
108 109
109 110
    def _read(self, last_pass=False):
110 111
        self.lines = list(self.file.get_lines(size=1024 * 1024, last_pass=last_pass))
111 112
112 113
        for line in self.lines:
113 -
            if line.startswith("http_reqs"):
114 -
                self.data['timestamp'].append(int(line.split(',')[1]))
115 -
                self.data['label'].append(line.split(',')[9])
116 -
                self.data['r_code'].append(line.split(',')[13])
117 -
                self.data['error_msg'].append(line.split(',')[4])
114 +
            if line.startswith("metric_name"):
115 +
                parts = line[:-1].split(",")
116 +
                self.position['timestamp'] = parts.index('timestamp')
117 +
                self.position['metric_value'] = parts.index('metric_value')
118 +
                self.position['error'] = parts.index('error')
119 +
                self.position['name'] = parts.index('name')
120 +
                self.position['status'] = parts.index('status')
121 +
            elif line.startswith("http_reqs"):
122 +
                self.data['timestamp'].append(int(line.split(',')[self.position['timestamp']]))
123 +
                self.data['label'].append(line.split(',')[self.position['name']])
124 +
                self.data['r_code'].append(line.split(',')[self.position['status']])
125 +
                self.data['error_msg'].append(line.split(',')[self.position['error']])
118 126
            elif line.startswith("http_req_duration"):
119 -
                self.data['http_req_duration'].append(float(line.split(',')[2]))
127 +
                self.data['http_req_duration'].append(float(line.split(',')[self.position['metric_value']]))
120 128
            elif line.startswith("http_req_connecting"):
121 -
                self.data['http_req_connecting'].append(float(line.split(',')[2]))
129 +
                self.data['http_req_connecting'].append(float(line.split(',')[self.position['metric_value']]))
122 130
            elif line.startswith("http_req_tls_handshaking"):
123 -
                self.data['http_req_tls_handshaking'].append(float(line.split(',')[2]))
131 +
                self.data['http_req_tls_handshaking'].append(float(line.split(',')[self.position['metric_value']]))
124 132
            elif line.startswith("http_req_waiting"):
125 -
                self.data['http_req_waiting'].append(float(line.split(',')[2]))
133 +
                self.data['http_req_waiting'].append(float(line.split(',')[self.position['metric_value']]))
126 134
            elif line.startswith("vus") and not line.startswith("vus_max"):
127 -
                self.data['vus'].append(int(float(line.split(',')[2])))
135 +
                self.data['vus'].append(int(float(line.split(',')[self.position['metric_value']])))
128 136
            elif line.startswith("data_received"):
129 -
                self.data['data_received'].append(float(line.split(',')[2]))
137 +
                self.data['data_received'].append(float(line.split(',')[self.position['metric_value']]))
130 138
131 139
            if self.data['vus'] and len(self.data['data_received']) >= self.data['vus'][0] and \
132 140
                    len(self.data['http_req_waiting']) >= self.data['vus'][0]:
Files Coverage
bzt 90.31%
Project Totals (68 files) 90.31%
9536.2
TRAVIS_PYTHON_VERSION=3.8
TRAVIS_OS_NAME=linux
1
codecov:
2
  notify:
3
    require_ci_to_pass: yes
4

5
coverage:
6
  round: up
7

8
ignore:
9
  - bzt/resources
Sunburst
The inner-most circle is the entire project, moving away from the center are folders then, finally, a single file. The size and color of each slice is representing the number of statements and the coverage, respectively.
Icicle
The top section represents the entire project. Proceeding with folders and finally individual files. The size and color of each slice is representing the number of statements and the coverage, respectively.
Grid
Each block represents a single file in the project. The size and color of each block is represented by the number of statements and the coverage, respectively.
Loading