aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--markdown.py2
-rw-r--r--test-markdown.py4
-rw-r--r--tests/misc/blank.html0
-rw-r--r--tests/misc/blank.txt0
4 files changed, 3 insertions, 3 deletions
diff --git a/markdown.py b/markdown.py
index 181de1d..116a974 100644
--- a/markdown.py
+++ b/markdown.py
@@ -1628,7 +1628,7 @@ class Markdown:
@returns: A serialized XHTML body."""
#try :
- if source :
+ if source is not None: #Allow blank string
self.source = source
if not self.source :
diff --git a/test-markdown.py b/test-markdown.py
index b9f5cdf..94fdda4 100644
--- a/test-markdown.py
+++ b/test-markdown.py
@@ -232,7 +232,7 @@ def testDirectory(dir, measure_time = False) :
actual_output = ""
actual_lines = []
- md.source = ""
+ #md.source = ""
gc.collect()
mem = memory()
t = time.clock()
@@ -348,7 +348,7 @@ markdown = __import__(MARKDOWN_FILE)
#testDirectory("tests/basic")
-#testDirectory("tests/markdown-test", measure_time=True)
+testDirectory("tests/markdown-test", measure_time=True)
testDirectory("tests/misc", measure_time=True)
#testDirectory("tests/extensions-x-footnotes-toc")
diff --git a/tests/misc/blank.html b/tests/misc/blank.html
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/tests/misc/blank.html
diff --git a/tests/misc/blank.txt b/tests/misc/blank.txt
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/tests/misc/blank.txt