Hey Dean,

Thanks for the new series. One thing I noted for the series as a whole
is that there are a few small errors being thrown by the formatting
script. One of the errors is on a method I wrote and gave you so I
apologize for that, it looks like I changed a parameter to a method
but didn't switch what I passed in when I called it.

Outside of the formatting issues I just had a few small comments,
otherwise it looks good to me. I did also update some of the methods
used in this series in my dynamic queue suite, but the functionality
should still be the same as what you have here so I'm unsure if it is
worth pulling in my other changes or keeping what you have and
resolving it at the time of merge.

On Fri, Jun 28, 2024 at 12:20 PM Dean Marx <dm...@iol.unh.edu> wrote:
>
> added set promisc, set verbose, and port stop
> commands to testpmd shell.
>
> Signed-off-by: Dean Marx <dm...@iol.unh.edu>
> ---
<snip>
> +    def set_verbose(self, level: int, verify: bool = True):
> +        """Set debug verbosity level.
> +
> +        Args:
> +            level: 0 - silent except for error
> +            1 - fully verbose except for Tx packets
> +            2 - fully verbose except for Rx packets
> +            >2 - fully verbose

We should probably indent these 3 lines like they are in the VLAN test suite.



> +            verify: if :data:`True` an additional command will be sent to 
> verify that verbose level
> +                is properly set. Defaults to :data:`True`.
> +
> +        Raises:
> +            InteractiveCommandExecutionError: If `verify` is :data:`True` 
> and verbose level
> +            is not correctly set.
> +        """
> +        verbose_output = self.send_command(f"set verbose {level}")
> +        if verify:
> +            if "Change verbose level" not in verbose_output:
> +                self._logger.debug(f"Failed to set verbose level to {level}: 
> \n{verbose_output}")
> +                raise InteractiveCommandExecutionError(
> +                    f"Testpmd failed to set verbose level to {level}."
> +                )
> +
>      def close(self) -> None:
>          """Overrides :meth:`~.interactive_shell.close`."""
>          self.send_command("quit", "")
> --
> 2.44.0
>

Reply via email to