Fix IndexError in test_no_pfc#12263
Merged
bingwang-ms merged 1 commit intosonic-net:masterfrom Apr 2, 2024
Merged
Conversation
Collaborator
Author
|
MSFT ADO: 27317506 |
lolyu
approved these changes
Apr 2, 2024
Collaborator
Author
|
@StormLiangMS Please help approve the cherry-pick. Thanks! |
mssonicbld
pushed a commit
to mssonicbld/sonic-mgmt
that referenced
this pull request
Apr 3, 2024
mssonicbld
pushed a commit
to mssonicbld/sonic-mgmt
that referenced
this pull request
Apr 3, 2024
Collaborator
|
Cherry-pick PR to 202305: #12295 |
Collaborator
|
Cherry-pick PR to 202311: #12296 |
This was referenced Apr 3, 2024
mssonicbld
pushed a commit
that referenced
this pull request
Apr 3, 2024
mssonicbld
pushed a commit
that referenced
this pull request
Apr 3, 2024
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description of PR
The PR is to fix
IndexErrorin test casetest_no_pfc.The error is because the fixture
lossless_prio_dscp_mapalways selects the first port inPORT_QOS_MAPtable as the testing port, and selects the first profile inDSCP_TO_TC_MAPto get the DSCP to TC map. So on some particular topo, we saw theIndexErrorbecause the selected profile is not applied to the testing port.This PR fixed the issue by checking the lossless priority and
lossless_prio_dscp_mapas well. The test case will be skipped if the extra lossless queue is not enabled on this port or the maplossless_prio_dscp_mapfor a particular priority is empty.Summary:
Fixes
IndexErrorin test casetest_no_pfc.Type of change
Back port request
Approach
What is the motivation for this PR?
This PR is to address
IndexErrorintest_no_pfc.How did you do it?
This PR fixed the issue by checking the lossless priority and
lossless_prio_dscp_mapas well. The test case will be skipped if the extra lossless queue is not enabled on this port or the maplossless_prio_dscp_mapfor a particular priority is empty.How did you verify/test it?
Verified on a dualtor testbed where I saw the new failure. Test can pass now.
Any platform specific information?
No.
Supported testbed topology if it's a new test case?
Not a new test case.
Documentation