Skip to content

Commit

Permalink
zephyr: mesh: add missing wids and update ixit values
Browse files Browse the repository at this point in the history
- Adding the missing WID fuctions 423 and 661.
- Move the test case MESH/NODE/TNPT/BV-13-C to persistent
storage test group since it need reset during the test.
- Removing invalid pixit values from unrelated mesh test
layers.

Signed-off-by: Alperen Şener <alperen.sener@nordicsemi.no>
  • Loading branch information
m-alperen-sener authored and mkasenberg committed Jan 15, 2024
1 parent f8d71b9 commit 4b49f90
Show file tree
Hide file tree
Showing 5 changed files with 34 additions and 19 deletions.
1 change: 1 addition & 0 deletions autopts/bot/iut_config/zephyr.py
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,7 @@
'MESH/SR/RPR/PDU/BI-03-C',
'MESH/NODE/CFG/COMP/BV-01-C'
'MESH/SR/RPR/LNK/BI-05-C',
'MESH/NODE/TNPT/BV-13-C',
]
},

Expand Down
2 changes: 1 addition & 1 deletion autopts/ptsprojects/zephyr/dfu.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ def set_pixits(ptses):
pts.set_pixit("DFU", "TSPX_device_uuid2", "001BDC0810210B0E0A0C000B0E0A0C00")
pts.set_pixit("DFU", "TSPX_use_pb_gatt_bearer", "FALSE")
pts.set_pixit("DFU", "TSPX_iut_comp_data_page", "0")
pts.set_pixit("DFU", "TSPX_OOB_state_change", "FALSE")
pts.set_pixit("DFU", "TSPX_oob_state_change", "FALSE")
pts.set_pixit("DFU", "TSPX_enable_IUT_provisioner", "FALSE")
pts.set_pixit("DFU", "TSPX_Procedure_Timeout", "60")
pts.set_pixit("DFU", "TSPX_Client_BLOB_ID", "1100000000000011")
Expand Down
3 changes: 1 addition & 2 deletions autopts/ptsprojects/zephyr/mbt.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,12 +60,11 @@ def set_pixits(ptses):
pts.set_pixit("MBT", "TSPX_device_uuid2", "001BDC0810210B0E0A0C000B0E0A0C00")
pts.set_pixit("MBT", "TSPX_use_pb_gatt_bearer", "FALSE")
pts.set_pixit("MBT", "TSPX_iut_comp_data_page", "0")
pts.set_pixit("MBT", "TSPX_OOB_state_change", "FALSE")
pts.set_pixit("MBT", "TSPX_oob_state_change", "FALSE")
pts.set_pixit("MBT", "TSPX_enable_IUT_provisioner", "FALSE")
pts.set_pixit("MBT", "TSPX_Procedure_Timeout", "60")
pts.set_pixit("MBT", "TSPX_Client_BLOB_ID", "1100000000000011")
pts.set_pixit("MBT", "TSPX_Client_BLOB_Data", r"data.txt")
pts.set_pixit("MBT", "TSPX_TTL", "2")
pts.set_pixit("MBT", "TSPX_Reception_Counter", "1")
pts.set_pixit("MBT", "TSPX_Server_Timeout", "20")
pts.set_pixit("MBT", "TSPX_Transfer_TTL", "3")
Expand Down
17 changes: 2 additions & 15 deletions autopts/ptsprojects/zephyr/mmdl.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,17 +56,10 @@ def set_pixits(ptses):
pts.set_pixit("MMDL", "TSPX_device_uuid", "00000000000000000000000000000000")
pts.set_pixit("MMDL", "TSPX_device_uuid2", "001BDC0810210B0E0A0C000B0E0A0C00")
pts.set_pixit("MMDL", "TSPX_use_pb_gatt_bearer", "FALSE")
pts.set_pixit("MMDL", "TSPX_OOB_state_change", "FALSE")
pts.set_pixit("MMDL", "TSPX_oob_state_change", "FALSE")
pts.set_pixit("MMDL", "TSPX_sensor_property_ids", "1,0069,0010,FFF0")
pts.set_pixit("MMDL", "TSPX_enable_IUT_provisioner", "FALSE")
pts.set_pixit("MMDL", "TSPX_cadence_property_IDs", "1,0069,0010,FFF0")
pts.set_pixit("MMDL", "TSPX_Procedure_Timeout", "60")
pts.set_pixit("MMDL", "TSPX_Server_Timeout", "10")
pts.set_pixit("MMDL", "TSPX_Client_BLOB_Data", r"data.txt")
pts.set_pixit("MMDL", "TSPX_New_Firmware_Image", r"data2.txt")
pts.set_pixit("MMDL", "TSPX_Update_Firmware_Image_Index", "0")
pts.set_pixit("MMDL", "TSPX_Client_BLOB_ID", "1100000000000011")
pts.set_pixit("MMDL", "TSPX_Reception_Counter", "1")


def test_cases(ptses):
Expand Down Expand Up @@ -118,13 +111,7 @@ def test_cases(ptses):
"MMDL", "TSPX_device_uuid2", stack.mesh.get_dev_uuid_lt2())),
TestFunc(lambda: pts.update_pixit_param(
"MMDL", "TSPX_bd_addr_iut",
stack.gap.iut_addr_get_str())),
TestFunc(lambda: pts.update_pixit_param(
"MMDL", "TSPX_Client_BLOB_Data",
get_test_data_path(pts) + "sample_data_1.txt")),
TestFunc(lambda: pts.update_pixit_param(
"MMDL", "TSPX_New_Firmware_Image",
get_test_data_path(pts) + "sample_data_1.txt"))]
stack.gap.iut_addr_get_str()))]

test_case_name_list = pts.get_test_case_list('MMDL')
tc_list = []
Expand Down
30 changes: 29 additions & 1 deletion autopts/wid/mesh.py
Original file line number Diff line number Diff line change
Expand Up @@ -1958,6 +1958,12 @@ def hdl_wid_394(_: WIDParams):
btp.mesh_proxy_identity()
return True

def hdl_wid_423(_: WIDParams):
"""
Implements:
description: PTS expects IUT not to send DIRECTED_PROXY_CAPABILITIES_STATUS message.
"""
return True

def hdl_wid_500(params: WIDParams):
"""
Expand Down Expand Up @@ -2476,7 +2482,6 @@ def hdl_wid_515(params: WIDParams):

return [net_key_index, app_key_idx, app_key_up] == stack.mesh.model_data


def parse_command_parameters(desc):
field_dict = {}
txt = desc.splitlines()[1:]
Expand Down Expand Up @@ -3225,6 +3230,29 @@ def hdl_wid_650(params: WIDParams):

return stack.mesh.status == 0x01

def hdl_wid_661(params: WIDParams):
"""
Implements:
Description: Please reset the IUT. Click OK when IUT is powered up after reset.
"""

stack = get_stack()

if not stack.mesh.is_initialized:
btp.mesh_config_prov()
btp.mesh_start()

zephyrctl = btp.get_iut_method()

zephyrctl.wait_iut_ready_event()
btp.core_reg_svc_gap()
btp.core_reg_svc_mesh()
btp.mesh_init()
btp.gap_read_ctrl_info()

btp.mesh_start()

return True

def hdl_wid_672(_: WIDParams):
"""
Expand Down

0 comments on commit 4b49f90

Please sign in to comment.