[PATCH v7 1/7] dts: add startup verification and forwarding modes to testpmd shell

Juraj Linkeš juraj.linkes at pantheon.tech
Wed Jan 10 14:18:06 CET 2024


> diff --git a/dts/framework/remote_session/testpmd_shell.py b/dts/framework/remote_session/testpmd_shell.py
> index 0184cc2e71..11c5c7f93c 100644
> --- a/dts/framework/remote_session/testpmd_shell.py
> +++ b/dts/framework/remote_session/testpmd_shell.py
<snip>
> @@ -82,3 +182,50 @@ def get_devices(self) -> list[TestPmdDevice]:
>              if "device name:" in line.lower():
>                  dev_list.append(TestPmdDevice(line))
>          return dev_list
> +
> +    def wait_link_status_up(self, port_id: int, timeout=SETTINGS.timeout) -> bool:
> +        """Wait until the link status on the given port is "up".
> +
> +        Arguments:
> +            port_id: Port to check the link status on.
> +            timeout: Time to wait for the link to come up. The default value for this
> +                argument may be modified using the :option:`-t, --timeout` command-line argument

This should be just :option:`--timeout`, otherwise Sphinx complains:
WARNING: unknown option: '-t, --timeout'

> +                or the :envvar:`DTS_TIMEOUT` environment variable.
> +
> +        Returns:
> +            Whether the link came up in time or not.
> +        """


More information about the dev mailing list