Conversation
singhavnish2516
commented
Apr 6, 2026
- Add a temp test to validate AFT Get Request (Subscribe Once)
Summary of ChangesHello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request simplifies the AFT base test suite by replacing a multi-step churn verification process with a direct, efficient validation of AFT entries. The changes streamline the test setup, remove legacy hardware profile handling, and introduce a more robust verification mechanism for IPv4 and IPv6 prefixes. Highlights
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here. Footnotes
|
Pull Request Functional Test Report for #5305 / c4e733cVirtual Devices
Hardware Devices
|
There was a problem hiding this comment.
Code Review
This pull request refactors the afts_base_test.go file by simplifying IPv6 prefix constants, removing the debug_notifications flag, and streamlining the AFT data collection and comparison logic. The test structure in TestBGP was significantly modified, replacing a complex multi-step churn test with a more direct verification of IPv4 and IPv6 prefixes using a new verifyAFT helper function. Feedback was provided regarding the hardcoded 5-minute timeout for prefix verification, suggesting it be defined as a constant for better reusability and adjusted to prevent premature failures.
| if duration > 5*time.Minute { | ||
| t.Errorf("Prefix verification took %v, want <= 5 minutes", duration) | ||
| } |
There was a problem hiding this comment.
The duration check for prefix verification (5 minutes) may be too restrictive. In tests involving convergence, timeouts must be sufficiently long to prevent premature failure. Additionally, consider defining this as a general constant to promote reusability across different vendors and test scales, rather than hardcoding it.
References
- In tests that inject artificial latency, convergence timeouts must be sufficiently long to account for the added delay and prevent premature test failure.
- Constants that may be applicable to multiple vendors in the future should be kept general, even if they are currently used in a vendor-specific context, to promote reusability.
paramasivamn1
left a comment
There was a problem hiding this comment.
Hi Avnish, Can you add the key requirements for this changes and also our observation so that reviewers will get the context and behavior. so that they can provide the possible optimization or other inputs.