From 9fa0aef913e76f2b40efbd6657749235eb26f160 Mon Sep 17 00:00:00 2001 From: Vratko Polak Date: Mon, 28 Oct 2019 13:23:58 +0100 Subject: TrafficGenerator: Skip only the first equals HRDhistogram output contains essential trailing equals. Edit all fields even though we do not expect equals in others. Change-Id: I9f4f07fc4d6f4583989a9c0e45f68bc0cd9a65fe Signed-off-by: Vratko Polak --- resources/libraries/python/TrafficGenerator.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'resources/libraries') diff --git a/resources/libraries/python/TrafficGenerator.py b/resources/libraries/python/TrafficGenerator.py index 82a5bf8203..751dc8885f 100644 --- a/resources/libraries/python/TrafficGenerator.py +++ b/resources/libraries/python/TrafficGenerator.py @@ -400,12 +400,12 @@ class TrafficGenerator(AbstractMeasurer): line = stdout.splitlines()[-1] self._result = line logger.info('TrafficGen result: {0}'.format(self._result)) - self._received = self._result.split(', ')[1].split('=')[1] - self._sent = self._result.split(', ')[2].split('=')[1] - self._loss = self._result.split(', ')[3].split('=')[1] + self._received = self._result.split(', ')[1].split('=', 1)[1] + self._sent = self._result.split(', ')[2].split('=', 1)[1] + self._loss = self._result.split(', ')[3].split('=', 1)[1] self._latency = [] - self._latency.append(self._result.split(', ')[4].split('=')[1]) - self._latency.append(self._result.split(', ')[5].split('=')[1]) + self._latency.append(self._result.split(', ')[4].split('=', 1)[1]) + self._latency.append(self._result.split(', ')[5].split('=', 1)[1]) def trex_stl_stop_remote_exec(self, node): """Execute script on remote node over ssh to stop running traffic. -- cgit 1.2.3-korg