The Scientific World Journal / 2015 / Article / Code 1

Research Article

An Approach to Model Based Testing of Multiagent Systems

Code 1

Find_all_paths function.
def find_all_paths (names, graph, start, end, pathof=
      “start”, “end”, “message”, “action”, “precept”, path=):
 path = path + start
if start end:
return  path
if not graph.has_key (start):
return  
 paths =
for node in graph start:
if names node1 in pathof:
  if path. count(node) <2:
    newpaths = find_all_paths (names, graph, node, end, pathof, path)
    for newpath in newpaths:
     paths. append (newpath)
return paths

Article of the Year Award: Outstanding research contributions of 2020, as selected by our Chief Editors. Read the winning articles.