mirror of
https://github.com/espressif/openthread.git
synced 2026-07-28 22:57:47 +00:00
[thci] fix THCI for T1.1 9.2.4 commissioner (#7311)
During running T.1.1 tests with the T.1.2 capable sample it turned out that 9.2.4 commissioner TC is not working when using the device that is T.1.2 capable. The reason is that in MGMT_ACTIVE_SET listSecurityPolicy list has only two elements and we are entering the code, where we assume it is three element, which raises IndexError.
This commit is contained in:
@@ -2825,11 +2825,8 @@ class OpenThreadTHCI(object):
|
||||
# new passing way listSecurityPolicy=[3600, 0b11001111]
|
||||
rotationTime = listSecurityPolicy[0]
|
||||
# bit order
|
||||
if TESTHARNESS_VERSION == TESTHARNESS_1_2:
|
||||
if self.DeviceCapability != DevCapb.V1_1:
|
||||
policyBits = listSecurityPolicy[2] << 8 | listSecurityPolicy[1]
|
||||
else:
|
||||
policyBits = listSecurityPolicy[1]
|
||||
if len(listSecurityPolicy) > 2:
|
||||
policyBits = listSecurityPolicy[2] << 8 | listSecurityPolicy[1]
|
||||
else:
|
||||
policyBits = listSecurityPolicy[1]
|
||||
|
||||
|
||||
Reference in New Issue
Block a user