Пример #1
0
def create_lossess_compare_tests(tag, files):

    for rst_file in files:
        testcase_name = mkclassname(rst_file)

        # Lossless

        TestCase = new_writer_testcase(tag, testcase_name, rst_file, False)
        setattr(sys.modules[__name__], testcase_name, TestCase)
Пример #2
0
def create_lossy_pxml_compare_tests(files):

    for acw_file, pxml_file in files:
        testcase_name = mkclassname(acw_file)

        # Lossy
        TestCase = new_writer_testcase("atlassian-mpe", testcase_name, acw_file, True)
        TestCase.__module__ = __name__
        setattr(sys.modules[__name__], testcase_name, TestCase)
Пример #3
0
def create_srcwriter_tests(files):
    """
    Test confluence writer as re-writer.

    - Parse confluence, and write pxml and confluence.

    * Compare generated confluence with source for lossless test.
    * Re-parse generated confluence, and compare pxml tree for lossy test.
    """

    for acw_file, pxml_file in files:
        testcase_name = mkclassname(acw_file)

        # Lossy
        TestCase = new_writer_testcase('confluence', testcase_name, acw_file, True)
        TestCase.__module__ = __name__
        setattr(sys.modules[__name__], testcase_name, TestCase)