def test_toctree_with_rst(feature_tree): expected_results = [ "Read me first\n\n", ".. toctree::\n", " :maxdepth: 2\n\n", " feature_root0.test.feature-file\n", ] results = writer.toctree(["feature_root0"], [], ["test.feature", "readme.rst"], 2, feature_tree.parent) assert results._output == expected_results
def test_toctree(feature_tree): expected_results = [ "Root0\n", "=====\n\n", ".. toctree::\n", " :maxdepth: 2\n\n", " root0.test.feature-file\n", ] results = writer.toctree(["root0"], [], ["test.feature"], 2, feature_tree.parent) assert results._output == expected_results