aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorMichael Williamson <mike@zwobble.org>2015-02-08 20:24:47 +0000
committerMichael Williamson <mike@zwobble.org>2015-02-08 20:24:47 +0000
commitd23efd5811e1ebeae915fdfb2cd8e8ede6b0f0ca (patch)
tree4f23a938ff1512a2b8deecfa046077dccc35734a /tests
parent1236e907e724926dedfac0695b1eedbe0acf226f (diff)
Ignore anchor tags with no href attribute
Diffstat (limited to 'tests')
-rw-r--r--tests/writers/markdown_tests.py9
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/writers/markdown_tests.py b/tests/writers/markdown_tests.py
index bfa1e1b..9448b50 100644
--- a/tests/writers/markdown_tests.py
+++ b/tests/writers/markdown_tests.py
@@ -85,6 +85,15 @@ def anchor_tags_are_written_as_hyperlinks():
assert_equal("[Hello](http://example.com)", writer.as_string())
+@istest
+def anchor_tags_without_href_attribute_are_treated_as_ordinary_text():
+ writer = _create_writer()
+ writer.start("a");
+ writer.text("Hello");
+ writer.end("a");
+ assert_equal("Hello", writer.as_string())
+
+
def _create_writer():
return MarkdownWriter()