diff options
author | Artem Yunusov <nedrlab@gmail.com> | 2008-08-24 00:00:52 +0500 |
---|---|---|
committer | Artem Yunusov <nedrlab@gmail.com> | 2008-08-24 00:00:52 +0500 |
commit | 00436cb6579dda584aa085a4c4610c4593da7050 (patch) | |
tree | 5dc3711730db8bbd71d74f000ac7d517cfcf04a7 | |
parent | fa014ac7743836db611713ca630a4919e8d5fa3d (diff) | |
download | markdown-00436cb6579dda584aa085a4c4610c4593da7050.tar.gz markdown-00436cb6579dda584aa085a4c4610c4593da7050.tar.bz2 markdown-00436cb6579dda584aa085a4c4610c4593da7050.zip |
Added final results to test script.
-rw-r--r-- | test-markdown.py | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/test-markdown.py b/test-markdown.py index 3ccda05..ee79afa 100644 --- a/test-markdown.py +++ b/test-markdown.py @@ -223,6 +223,7 @@ def testDirectory(dir, measure_time=False, safe_mode=False) : diffsBuffer = "" + for test in tests : print "--- %s ---" % test @@ -268,7 +269,8 @@ def testDirectory(dir, measure_time=False, safe_mode=False) : htmlDiffFile.write("<td class='ok'>OK</td>") else : - + + failedTests.append(test) htmlDiffFile.write("<td class='failed'>" + "<a href='#diff-%s'>FAILED</a></td>" % test) @@ -312,6 +314,7 @@ def testDirectory(dir, measure_time=False, safe_mode=False) : benchmark_file = open(benchmark_output_file_name, "w") benchmark_file.write(benchmark_buffer) benchmark_file.close() + def get_benchmark_html (actual, expected) : @@ -353,6 +356,7 @@ print MARKDOWN_FILE markdown = __import__(MARKDOWN_FILE) +failedTests = [] #testDirectory("tests/basic") testDirectory("tests/markdown-test", measure_time=True) @@ -366,3 +370,9 @@ testDirectory("tests/safe_mode", measure_time=True, safe_mode="escape") testDirectory("tests/extensions-x-codehilite") testDirectory("tests/extensions-x-wikilink") +print "\n### Final result ###" +if len(failedTests): + print "%d failed tests: %s" % (len(failedTests), str(failedTests)) +else: + print "All tests passed, no errors!" + |