Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

snappi has to provide a backend capabilities list #188

Open
anton7811 opened this issue Sep 23, 2022 · 0 comments
Open

snappi has to provide a backend capabilities list #188

anton7811 opened this issue Sep 23, 2022 · 0 comments
Assignees
Labels
enhancement New feature or request

Comments

@anton7811
Copy link

When I'm writing a script using snappi I want to be able to execute it against multiple TG backends (Ixia-C or IxNet).
And I want to have a smart way to skip some logic if it is not supported. That could be something like a get_capability() call.

Real-world example:
I'm creating a test suite with traffic that is expected to be running on the emulator and real hardware. In the first case I will be using Ixia-C, and in the 2d - IxNetwork. But I don't want to make any changes in the test code.
So I should be able to do one of two:

  1. Skip the test e.g. in pytest - @pytest.skipif(snappi.get_capabilities().vxlan_control_plane == False)
  2. In the code itself do some ifs:
if snappi.get_capabilities().vxlan_control_plane == True:
    do_extra_configuration()
else:
    logging.warning("Skipping VXLAN control plane configuration")
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
enhancement New feature or request
Projects
Status: Backlog
Development

No branches or pull requests

3 participants