mirror of
https://github.com/espressif/openthread.git
synced 2026-09-17 14:40:07 +00:00
[tests] update test_detach to be more robust (#12299)
The router processes its child table every second. After a child gracefully detaches, wait some time to ensure that the router has processed the child table entry.
This commit is contained in:
@@ -98,6 +98,7 @@ class TestDetach(thread_cert.TestCase):
|
|||||||
|
|
||||||
child1.detach()
|
child1.detach()
|
||||||
self.assertEqual(child1.get_state(), 'disabled')
|
self.assertEqual(child1.get_state(), 'disabled')
|
||||||
|
self.simulator.go(2) # The router processes its child table every second; wait 2s to be safe.
|
||||||
self.assertFalse(router1.get_child_table())
|
self.assertFalse(router1.get_child_table())
|
||||||
|
|
||||||
router1.detach()
|
router1.detach()
|
||||||
|
|||||||
Reference in New Issue
Block a user