+ @staticmethod
+ def clear_interface_counters_on_all_duts(nodes):
+ """Clear interface counters on all DUTs.
+
+ :param nodes: VPP nodes.
+ :type nodes: dict
+ """
+ for node in nodes.values():
+ if node['type'] == NodeType.DUT:
+ VppCounters.vpp_clear_interface_counters(node)
+
+ @staticmethod
+ def vpp_clear_hardware_counters(node):
+ """Clear interface hardware counters on VPP node.
+
+ :param node: Node to clear hardware counters on.
+ :type node: dict
+ """
+ vat = VatExecutor()
+ vat.execute_script('clear_hardware.vat', node)
+ vat.script_should_have_passed()
+
+ @staticmethod
+ def clear_hardware_counters_on_all_duts(nodes):
+ """Clear hardware counters on all DUTs.
+
+ :param nodes: VPP nodes.
+ :type nodes: dict
+ """
+ for node in nodes.values():
+ if node['type'] == NodeType.DUT:
+ VppCounters.vpp_clear_hardware_counters(node)
+
+ @staticmethod
+ def vpp_clear_errors_counters(node):
+ """Clear errors counters on VPP node.
+
+ :param node: Node to clear errors counters on.
+ :type node: dict
+ """
+ vat = VatExecutor()
+ vat.execute_script('clear_errors.vat', node)
+ vat.script_should_have_passed()
+
+ @staticmethod
+ def clear_error_counters_on_all_duts(nodes):
+ """Clear VPP errors counters on all DUTs.
+
+ :param nodes: VPP nodes.
+ :type nodes: dict
+ """
+ for node in nodes.values():
+ if node['type'] == NodeType.DUT:
+ VppCounters.vpp_clear_errors_counters(node)
+