def test_parseTestcase_parseWikiPage(build_trac_env): env = build_trac_env wikipage = WikiPage(env, "TcTestplanCreate") wikipage.text = TESTCASE.decode("utf-8") wikipage.save("pytest", "comment", "127.0.0.1") tcp = TestcaseParser(env) testcase = tcp.parseTestcase(pagename="TcTestplanCreate") assert len(testcase.actions) == 5
def test_parseTestcase_NotExistingWikiPage(build_trac_env): env = build_trac_env tcp = TestcaseParser(env) with pytest.raises(TracError): # a Wiki Page that doenst exist tcp.parseTestcase("NotExistingWikiPage")