保存测试用例

This commit is contained in:
2025-08-01 11:33:21 +08:00
parent 5eeeb98b58
commit f56ef8e077
5 changed files with 130 additions and 44 deletions

View File

@@ -267,6 +267,40 @@ def tc8():
genPkt.addSubPkt(0x0, 0, random.randint(0, 65535), 0xb, 2, data)
gen_file_def = "set_addr_pkt"
sm_idx = 0
genPkt.addAfterExc(genWriteTransLenCode(gen_file_def, sm_idx)
+genWriteTransPktCode(gen_file_def, sm_idx)
+genTrgTransPktCode(gen_file_def, sm_idx)
+genReadAckPktCode(gen_file_def, sm_idx))
genPkt.gen("./generated/shin/%s.vh"%(gen_file_def, ), 1)
return gen_file_def
def tc9():
genPkt = GenPkt()
gen_file_def = "base_tc09"
sm_idx = 0
tc_des = "测试8个ebmmu全配置下运行每两个ebmmu对应一个sm。每个ebmmu必须对齐、足长的写入\\n" \
+ "对应的sm才能正常工作。两次写入数据复位设备1的SM1SM1状态复原不能读取到有效的数据。\\n"\
+ "测试用例能成功运行完毕除设备1的SM1其余的SMx都能获得正确的数据。\\n\\n" \
+ "检查内容ebmmu工作状态、回包工作计数、SMx的状态、中断状态、统计信息、相关时序"
#-------------------------------------------------------------------------
#>>>>>>设置顺序地址
genPkt.clean()
genPkt.setPktType(0)
data = bytearray(b"\0" * 2)
data[0] = 0x3f
data[1] = 0xff
#subPkt参数索引、索引类型、地址、命令、长度、数据
genPkt.addSubPkt(0x0, 0, random.randint(0, 65535), 0xb, 2, data)
gen_file_def = "set_addr_pkt"
sm_idx = 0