5import isystem.connect
as ic
11def test_removeItems():
12 connMgr = ic.ConnectionMgr()
13 connMgr.connect(ic.CConnectionConfig().instanceId(winidea_id))
15 profCtrl = ic.CProfilerController2(connMgr,
"sdk_example.trd",
"w")
17 profCtrl.addFunction(0,
'main')
18 profCtrl.addFunction(0,
'target_init')
19 print(
"Removing function 'main' of trigger with index 0...")
20 a = profCtrl.removeFunction(0,
"main")
24 print(
"\tOK, already removed or not present.")
26 a = profCtrl.removeFunction(0,
"target_init")
30 print(
"\tOK, already removed or not present.")
32 print(
"Removing functions of trigger with index 0...")
33 profCtrl.removeAllFunctions(0)
35 print(
"Removing variable 'main_loop_counter' of trigger with index 0...")
36 if profCtrl.removeVariable(0,
"main_loop_counter") == 0:
39 print(
"\tOK, already removed or not present.")
41 print(
"Removing all variables of trigger with index 0...")
42 profCtrl.removeAllVariables(0)
43 profCtrl.closeDiscard()
46if __name__ ==
"__main__":