def parseTest( str, loc, toks): d={} if "message" in toks: d["message"]=toks["message"] if "class" in toks: d["class"] = toks["class"] d["deprecated"] = False if(toks[0]=="disabled"): d["deprecated"] = True if "PARAMID" in toks: d["PARAMID"] = toks["PARAMID"] if "testData" in toks: d["testData"]=toks["testData"] t = p.TreeElem(0) t.writeData(d) return(t)
def parseNodeGroup( str, loc, toks): d={} t = p.TreeElem(0) if "message" in toks: d["message"]=toks["message"] if "class" in toks["desc"]: d["class"] = toks["desc"]["class"] if "folder" in toks["desc"]: t.setPath(toks["desc"]["folder"]) d["deprecated"] = False if(toks[0]=="disabled"): d["deprecated"] = True t.writeData(d) #print(t.data["message"]) for c in toks["contained"]: #print(" ",c.data["message"]) t.addGroup(c) return(t)
def parseNodeSuite( str, loc, toks): d={} t = p.TreeElem(0) if "message" in toks: d["message"]=toks["message"] if "class" in toks["desc"]: d["class"] = toks["desc"]["class"] if "folder" in toks["desc"]: t.setPath(toks["desc"]["folder"]) d["deprecated"] = False if(toks[0]=="disabled"): d["deprecated"] = True if "PARAMID" in toks: d["PARAMID"] = toks["PARAMID"] t.writeData(d) if "params" in toks: t.params=toks["params"] for c in toks["allTests"]: t.addGroup(c) if "allPatterns" in toks: for c in toks["allPatterns"]: t.addPattern(c["ID"],c["path"]) if "allParams" in toks: for c in toks["allParams"]: if "path" in c: t.addParam(p.TreeElem.PARAMFILE,c["ID"],c["path"]) if "numberList" in c: #print(c["numberList"]) t.addParam(p.TreeElem.PARAMGEN,c["ID"],c["numberList"]) if "allOutputs" in toks: for c in toks["allOutputs"]: t.addOutput(c["ID"],c["path"]) return(t)