markdown-link-style

switch between inline and footnote link style in markdown documents.
git clone git://git.ricketyspace.net/markdown-link-style.git
Log | Files | Refs

commit 87969fb3f57e84ee070a90ea03126f2aba069ce3
parent 9b7dfcb956137ed085e6433180dcd6a24d662b2b
Author: rsiddharth <s@ricketyspace.net>
Date:   Mon, 20 Mar 2017 00:56:03 +0000

tests: Update `TestMDLSLogger.test_debug`

* tests/test_markdown_link_style/test_logging.py (TestMDLSLogger.test_debug)
(TestMDLSLogger.setup): Update methods.

Diffstat:
tests/test_markdown_link_style/test_logging.py | 11+++++++++--
1 file changed, 9 insertions(+), 2 deletions(-)

diff --git a/tests/test_markdown_link_style/test_logging.py b/tests/test_markdown_link_style/test_logging.py @@ -18,6 +18,10 @@ # along with markdown-link-style (see COPYING). If not, see # <http://www.gnu.org/licenses/>. +import sys + +from io import StringIO + from markdown_link_style.logging import MDLSLogger class TestMDLSLogger(object): @@ -26,10 +30,13 @@ class TestMDLSLogger(object): """ def setup(self): - self.logger = MDLSLogger('DebugTest') + self.stream = StringIO() + self.logger = MDLSLogger('TestLogger', self.stream) def test_debug(self): - self.logger.debug('DEBUG::MSG') + log_msg = 'DEBUG::MSG' + self.logger.debug(log_msg) + assert self.stream.getvalue().strip('\n') == log_msg def test_info(self): self.logger.info('INFO::MSG')