Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

feat(anta): Added testcases to verifying Route Type #925

Merged
merged 12 commits into from
Dec 20, 2024

Conversation

geetanjalimanegslab
Copy link
Collaborator

@geetanjalimanegslab geetanjalimanegslab commented Nov 14, 2024

Description

This test performs the following checks for each specific ipv4 route:
        1. Verify that the specified VRF is configured.
        2. Verifies that the specified ipv4 route exists in the configuration.
        3. Verify that the provided ipv4 route is of the expected type.

    Expected Results
    ----------------
    * Success:  If all of the following conditions are met:
        - All the specified VRFs are configured.
        - All the specified ipv4 routes are found.
        - All the specified ipv4 routes are of the expected type.
    * Failure:  If any of the following occur:
        - A specified VRF is not configured.
        - A specified ipv4 routes are found.
        - Any specified ipv4 route is not of the expected type.

Fixes #884

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my code
  • I have run pre-commit for code linting and typing (pre-commit run)
  • I have made corresponding changes to the documentation
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes (tox -e testenv)

@geetanjalimanegslab geetanjalimanegslab changed the title Issue_884: Added testcases for verifying Route Type feat(anta): Added testcases for verifying Route Type Nov 14, 2024
@geetanjalimanegslab geetanjalimanegslab changed the title feat(anta): Added testcases for verifying Route Type feat(anta): Added testcases to verifying Route Type Nov 14, 2024
examples/tests.yaml Outdated Show resolved Hide resolved
anta/custom_types.py Outdated Show resolved Hide resolved
anta/tests/routing/generic.py Outdated Show resolved Hide resolved
anta/tests/routing/generic.py Outdated Show resolved Hide resolved
anta/custom_types.py Outdated Show resolved Hide resolved
anta/input_models/routing/generic.py Outdated Show resolved Hide resolved
anta/tests/routing/generic.py Outdated Show resolved Hide resolved
anta/tests/routing/generic.py Outdated Show resolved Hide resolved
anta/tests/routing/generic.py Outdated Show resolved Hide resolved
anta/tests/routing/generic.py Outdated Show resolved Hide resolved
anta/tests/routing/generic.py Outdated Show resolved Hide resolved
anta/tests/routing/generic.py Outdated Show resolved Hide resolved
anta/tests/routing/generic.py Outdated Show resolved Hide resolved
tests/units/anta_tests/routing/test_generic.py Outdated Show resolved Hide resolved
Copy link

codspeed-hq bot commented Nov 24, 2024

CodSpeed Performance Report

Merging #925 will not alter performance

Comparing geetanjalimanegslab:issue_884 (ea56022) with main (f702c91)

Summary

✅ 22 untouched benchmarks

Copy link
Contributor

github-actions bot commented Dec 2, 2024

This pull request has conflicts, please resolve those before we can evaluate the pull request.

Copy link
Contributor

Conflicts have been resolved. A maintainer will review the pull request shortly.

anta/input_models/routing/generic.py Show resolved Hide resolved
anta/input_models/routing/generic.py Outdated Show resolved Hide resolved
anta/input_models/routing/generic.py Outdated Show resolved Hide resolved
anta/input_models/routing/generic.py Outdated Show resolved Hide resolved
anta/tests/routing/generic.py Outdated Show resolved Hide resolved
anta/tests/routing/generic.py Outdated Show resolved Hide resolved
anta/tests/routing/generic.py Outdated Show resolved Hide resolved
tests/units/anta_tests/routing/test_generic.py Outdated Show resolved Hide resolved
Copy link
Collaborator

@vitthalmagadum vitthalmagadum left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@vitthalmagadum vitthalmagadum marked this pull request as ready for review December 10, 2024 12:59
Copy link
Collaborator

@gmuloc gmuloc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Need to check if we could have multiple entries for the same route in a given VRF with different types in the JSON output - then I am not sure if this test would behave as we expect

@gmuloc gmuloc merged commit f440b30 into aristanetworks:main Dec 20, 2024
25 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add the test case to verify the route type(routes learned via)
3 participants