mirror of
https://github.com/espressif/openthread.git
synced 2026-09-01 06:49:54 +00:00
[nexus] fix intermittent failure in test 6.1.2 (#12472)
This commit fixes an intermittent failure in Nexus test 6.1.2 by setting the REED's router upgrade threshold to 0. By default, a REED may attempt to upgrade to a Router if the number of active routers in the network is below a certain threshold. In this test scenario, we want to ensure the REED remains a child until the appropriate point in the test sequence. Setting the threshold to 0 prevents premature promotion due to low router count, ensuring more deterministic test behavior.
This commit is contained in:
@@ -115,6 +115,7 @@ void RunTest6_1_2(Topology aTopology, const char *aJsonFile)
|
||||
VerifyOrQuit(leader.Get<Mle::Mle>().IsLeader());
|
||||
|
||||
reed.Join(leader);
|
||||
reed.Get<Mle::Mle>().SetRouterUpgradeThreshold(0);
|
||||
nexus.AdvanceTime(kReedToRouterTime);
|
||||
VerifyOrQuit(reed.Get<Mle::Mle>().IsChild());
|
||||
|
||||
|
||||
Reference in New Issue
Block a user