Skip to content

[everflow]: Make Policer test more robust#1393

Merged
liat-grozovik merged 2 commits intosonic-net:masterfrom
nazariig:master-everflow-policer
Feb 20, 2020
Merged

[everflow]: Make Policer test more robust#1393
liat-grozovik merged 2 commits intosonic-net:masterfrom
nazariig:master-everflow-policer

Conversation

@nazariig
Copy link
Contributor

@nazariig nazariig commented Feb 17, 2020

Signed-off-by: Nazarii Hnydyn [email protected]

Description of PR

Fixed everflow Policer test: logic was made more robust

Type of change

  • Bug fix
  • Test case(new/improvement)
  • Testbed and Framework(new/improvement)

Approach

How did you do it?

  • Changed packet generator logic: send all packets at full rate
  • Added CBS bucket refill calculation
  • Default tolerance is 10%

How did you verify/test it?

  1. Deploy t1-lag
  2. Run test
root@93d22705bd72:~# ./run.sh
everflow_policer_test.EverflowPolicerTest ...
Recieved 500 original packets
Received 100 mirrored packets after rate limiting
ok

----------------------------------------------------------------------
Ran 1 test in 3.423s

OK
  1. The test will print nice user friendly assert in case of failure
root@93d22705bd72:~# ./run.sh
everflow_policer_test.EverflowPolicerTest ...
Recieved 500 original packets
Received 88 mirrored packets after rate limiting
FAIL

======================================================================
FAIL: everflow_policer_test.EverflowPolicerTest
----------------------------------------------------------------------
Traceback (most recent call last):
  File "acstests/everflow_policer_test.py", line 212, in runTest
    assert count >= self.min_range and count <= self.max_range, assert_str
AssertionError: min(90) <= count(88) <= max(110)

----------------------------------------------------------------------
Ran 1 test in 2.911s

FAILED (failures=1)
No handlers could be found for logger "dataplane"

******************************************
ATTENTION: SOME TESTS DID NOT PASS!!!

The following tests failed:
EverflowPolicerTest

******************************************

Any platform specific information?

  • N/A

Supported testbed topology if it's a new test case?

  • N/A

Documentation

  • N/A

Copy link
Contributor

@qiluo-msft qiluo-msft left a comment

Choose a reason for hiding this comment

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

As comment

@nazariig nazariig requested a review from qiluo-msft February 19, 2020 17:40
@liat-grozovik liat-grozovik merged commit 89a4937 into sonic-net:master Feb 20, 2020
kazinator-arista pushed a commit to kazinator-arista/sonic-mgmt that referenced this pull request Mar 4, 2026
SWSS:
* d97c7c7 2021-04-07 | [Dynamic Buffer Calc] Enhancement: coding style and LGTM alerts (sonic-net#1693) (HEAD -> 202012) [Stephen Sun]
* f70b3da 2021-04-03 | [Makefile] Reorder libsaimetadata and libswsscommon (sonic-net#1689) [Kamil Cudnik]
* 72ae85d 2021-04-08 | [vlan] Add support of VLAN host interface (sonic-net#1645) [Volodymyr Samotiy]
* a555b9c 2021-04-02 | Correct the sflow default sample rate (sonic-net#1623) [fredyu190011]

Utilities:
* 1a789d2 2021-04-07 | Fixed the possibility of using uninitialized variable in route_check.py (sonic-net#1551) (HEAD -> 202012) [Renuka Manavalan]
* 2412e3c 2021-04-06 | Fix fast-reboot-dump.py SonicV2Connector after late merge (sonic-net#1546) [shlomibitton]
* f99c5f1 2021-04-02 | [fast-reboot] Fix dump script to support PortChannels in a VLAN group (sonic-net#1393) [shlomibitton]
* 716e2af 2021-04-04 | Reduce time taken by show commands on multi-asic platforms (sonic-net#1544) [abdosi]
* a160519 2021-04-03 | [setup.py]: move the module to test requirement (sonic-net#1542) [lguohan]
* eaa67fe 2021-04-04 | [config] Eliminate race condition between reloading Monit config and (sonic-net#1543) [yozhao101]
* 2497a9e 2021-04-03 | [reboot] No need enable the Linux magic system request key (sonic-net#1538) [yozhao101]
* 9fda6fe 2021-04-06 | [fwutil]: Fix next image mount (sonic-net#1533) [Nazarii Hnydyn]
* 9af50fe 2021-02-09 | Import 'mock' module from 'unittest' library (sonic-net#1415) (HEAD -> 202012) [Joe LeVeque]

Signed-off-by: Ying Xie <[email protected]>
kazinator-arista pushed a commit to kazinator-arista/sonic-mgmt that referenced this pull request Mar 4, 2026
 [sonic-swsss] Fix the issue of field "next_hop_ip" not getting updated
 in state DB in ERSPAN Mirror (sonic-net#1375)
[vlanmgr] Support Jumbo Frame By Default (sonic-net#1393)
[fec] added logic that put port down before applying fec
onfiguration (sonic-net#1399)
 [fec] Get FEC mode when port is already admin down (sonic-net#1403)
 Refine getDbId() calling to fix build after swss-common change
 (sonic-net#1245)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants