mirror of
https://github.com/espressif/openthread.git
synced 2026-08-01 00:27:47 +00:00
[test] extra wait on multiple prefix add in test_netdata_publisher (#6924)
This commit updates the `test_netdata_publisher` to add extra wait time between adds (where the same on-mesh prefix is published on all routers). This should help make the test robust and avoid the situation where publishing the same prefix on all routers all together could cause the number of entries in the Network Data to temporarily go above the desired number. This can happen (though not often) due to the randomness in how/when nodes using `Publisher` add their entry in the Network Data.
This commit is contained in:
@@ -416,7 +416,7 @@ class NetDataPublisher(thread_cert.TestCase):
|
||||
|
||||
for node in routers:
|
||||
node.netdata_publish_prefix(ON_MESH_PREFIX, ON_MESH_FLAGS, 'med')
|
||||
self.simulator.go(WAIT_TIME)
|
||||
self.simulator.go(WAIT_TIME)
|
||||
prefixes = leader.get_prefixes()
|
||||
self.check_num_of_prefixes(prefixes, 0, 1 + len(routers), 0)
|
||||
self.assertTrue(1 + len(routers) >= DESIRED_NUM_ON_MESH_PREFIX)
|
||||
|
||||
Reference in New Issue
Block a user