Skip to content

Commit

Permalink
AggregatedXDPBenchMeasurementResults: add individual_results
Browse files Browse the repository at this point in the history
For some reason this Aggregated class was missing the individual_results
property.

Signed-off-by: Ondrej Lichtner <[email protected]>
  • Loading branch information
olichtne committed Nov 26, 2024
1 parent 5870448 commit 012921b
Showing 1 changed file with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,14 @@
class AggregatedXDPBenchMeasurementResults(XDPBenchMeasurementResults):
def __init__(self, measurement, flow):
super().__init__(measurement, True, flow)
self._individual_results: list[TcRunMeasurementResults] = []
self._generator_results = SequentialPerfResult()
self._receiver_results = SequentialPerfResult()

@property
def individual_results(self) -> list[XDPBenchMeasurementResults]:
return self._individual_results

@property
def measurement_success(self) -> bool:
if self.individual_results:
Expand All @@ -22,9 +27,11 @@ def add_results(self, results):
if results is None:
return
elif isinstance(results, AggregatedXDPBenchMeasurementResults):
self._individual_results.extend(results.individual_results)
self.generator_results.extend(results.generator_results)
self.receiver_results.extend(results.receiver_results)
elif isinstance(results, XDPBenchMeasurementResults):
self._individual_results.append(results)
self.generator_results.append(results.generator_results)
self.receiver_results.append(results.receiver_results)
else:
Expand Down

0 comments on commit 012921b

Please sign in to comment.