Add docs for test formatter

This commit is contained in:
Ian Adam Naval 2015-02-26 18:22:51 -05:00
parent 781ae4b99c
commit f54ffc4136

View File

@ -3,6 +3,9 @@ from psh.commands import BaseCommand
from io import StringIO from io import StringIO
class TestFormatter(BaseCommand): class TestFormatter(BaseCommand):
"""Formatter useful for tests. Instead of printing to stdout, it
stores any output inside a stringio buffer. This can be retrieved
with the get_data method."""
def __init__(self, *args, **kwargs): def __init__(self, *args, **kwargs):
super(TestFormatter, self).__init__(*args, **kwargs) super(TestFormatter, self).__init__(*args, **kwargs)