diff options
author | Waylan Limberg <waylan@gmail.com> | 2008-12-08 11:51:41 -0500 |
---|---|---|
committer | Waylan Limberg <waylan@gmail.com> | 2008-12-08 11:51:41 -0500 |
commit | c1f4bc166fc6e95dbdf1c21a32cf6c89e7e8baf1 (patch) | |
tree | 7bea10a4bc86228aaa87bdd230ec4a6e30cf23df /test-markdown.py | |
parent | af38181495451e303364fab833d04c702ab05abe (diff) | |
download | markdown-c1f4bc166fc6e95dbdf1c21a32cf6c89e7e8baf1.tar.gz markdown-c1f4bc166fc6e95dbdf1c21a32cf6c89e7e8baf1.tar.bz2 markdown-c1f4bc166fc6e95dbdf1c21a32cf6c89e7e8baf1.zip |
Check for dependencies for the CodeHilite extension before running it's tests - avoiding known failures. Perhaps this should be a builtin feature of the tester, but this hack will do for now.
Diffstat (limited to 'test-markdown.py')
-rwxr-xr-x | test-markdown.py | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/test-markdown.py b/test-markdown.py index e5a4374..f3be36e 100755 --- a/test-markdown.py +++ b/test-markdown.py @@ -320,12 +320,19 @@ def run_tests() : tester.test_directory("tests/extensions-x-footnotes") #tester.test_directory("tests/extensions-x-ext1-ext2") tester.test_directory("tests/safe_mode", measure_time=True, safe_mode="escape") - tester.test_directory("tests/extensions-x-codehilite") tester.test_directory("tests/extensions-x-wikilinks") tester.test_directory("tests/extensions-x-toc") tester.test_directory("tests/extensions-x-def_list") tester.test_directory("tests/extensions-x-abbr") - + + try: + import pygments + except ImportError: + # Dependancy not avalable - skip test + pass + else: + tester.test_directory("tests/extensions-x-codehilite") + print "\n### Final result ###" if len(tester.failedTests): print "%d failed tests: %s" % (len(tester.failedTests), str(tester.failedTests)) |