~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_help.py

  • Committer: Canonical.com Patch Queue Manager
  • Date: 2011-05-19 10:51:37 UTC
  • mfrom: (5891.1.3 api-docs)
  • Revision ID: pqm@pqm.ubuntu.com-20110519105137-amzagrral2ldm1lq
(spiv) Fix the formatting of more docstrings. (Andrew Bennetts)

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
# Copyright (C) 2007-2010 Canonical Ltd
 
1
# Copyright (C) 2007-2011 Canonical Ltd
2
2
#
3
3
# This program is free software; you can redistribute it and/or modify
4
4
# it under the terms of the GNU General Public License as published by
16
16
 
17
17
"""Unit tests for the bzrlib.help module."""
18
18
 
19
 
from cStringIO import StringIO
20
 
 
21
19
from bzrlib import (
22
20
    builtins,
23
21
    commands,
112
110
                Example 2::
113
111
 
114
112
                    cmd arg2
 
113
 
 
114
                A code block follows.
 
115
 
 
116
                ::
 
117
 
 
118
                    bzr Demo something
115
119
            """
116
120
        cmd = cmd_Demo()
117
121
        helptext = cmd.get_help_text()
134
138
            '    Example 2:\n'
135
139
            '\n'
136
140
            '        cmd arg2\n'
 
141
            '\n'
 
142
            '    A code block follows.\n'
 
143
            '\n'
 
144
            '        bzr Demo something\n'
137
145
            '\n')
138
146
        helptext = cmd.get_help_text(plain=False)
139
147
        self.assertEquals(helptext,
154
162
            '    Example 2::\n'
155
163
            '\n'
156
164
            '        cmd arg2\n'
 
165
            '\n'
 
166
            '    A code block follows.\n'
 
167
            '\n'
 
168
            '    ::\n'
 
169
            '\n'
 
170
            '        bzr Demo something\n'
157
171
            '\n')
158
172
 
159
173
    def test_concise_help_text(self):