:py:mod:`json2graph.tests.test_aux` =================================== .. py:module:: json2graph.tests.test_aux .. autoapi-nested-parse:: Auxiliary test functions. Module Contents --------------- Functions ~~~~~~~~~ .. autoapisummary:: json2graph.tests.test_aux.get_test_list json2graph.tests.test_aux.print_graphs_differences json2graph.tests.test_aux.compare_graphs .. py:function:: get_test_list() Return a list with all JSON files in the test_files folder. :return: List with complete path of all JSON files in the test_files folder. :rtype: list[str] .. py:function:: print_graphs_differences(iso_result_graph, iso_expected_graph, test_name) Print three files: - test*_both.ttl: contains the statements that are present in both the resulting and expected graphs. - test*_or.ttl: contains the statements that are present only in the resulting graph. - test*_oe.ttl: contains the statements that are present only in the expected graph. :param iso_result_graph: Isomorphic resulting graph. :type iso_result_graph: Graph :param iso_expected_graph: Isomorphic expected graph. :type iso_expected_graph: Graph :param test_name: Name of the test to be used for printing comparison if evaluation result is negative. :type test_name: str .. py:function:: compare_graphs(resulting_graph_path, expected_graph_path, test_name) Verify if resulting graph corresponds to expected graph. :param resulting_graph_path: Path to the generated resulting graph file. :type resulting_graph_path: str :param expected_graph_path: Path to the expected graph file. :type expected_graph_path: str :param test_name: Name of the test to be used for printing comparison if evaluation result is negative. :type test_name: str :return: Boolean value indicating if the resulting and expected graphs are equal. :rtype: bool