Files
NikolajDanger c215157190
2023-01-04 17:03:44 +01:00

29 lines
597 B
Python

"""
Usage:
main.py DCR LOG
Options:
DCR The DCR graph in xml format
LOG The log in csv format
"""
import copy
from docopt import docopt
from DCR_graph import xml_to_dcr
from log import read_log
from conformance_testing import conformance_test
def main():
arguments = docopt(__doc__)
graph = xml_to_dcr(arguments["DCR"])
logs = read_log(arguments["LOG"])
tests = [conformance_test(trace[1], copy.deepcopy(graph)) for trace in logs]
print("Success: ", tests.count(True))
print("Failure: ", tests.count(False))
if __name__ == "__main__":
main()