~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: 2009-02-23 17:00:36 UTC
  • mfrom: (4032.1.4 jam-integration)
  • Revision ID: pqm@pqm.ubuntu.com-20090223170036-3q1v68ewdt8i0to5
(Marius Kruger) Remove all trailing whitespace and add tests to
        enforce this.

Show diffs side-by-side

added added

removed removed

Lines of Context:
96
96
        """Help text should be plain text by default."""
97
97
        class cmd_Demo(commands.Command):
98
98
            """A sample command.
99
 
 
 
99
 
100
100
            :Examples:
101
101
                Example 1::
102
 
 
 
102
 
103
103
                    cmd arg1
104
 
 
 
104
 
105
105
                Example 2::
106
 
 
 
106
 
107
107
                    cmd arg2
108
108
            """
109
109
        cmd = cmd_Demo()
151
151
        """Help text may contain a custom usage section."""
152
152
        class cmd_Demo(commands.Command):
153
153
            """A sample command.
154
 
 
 
154
 
155
155
            :Usage:
156
156
                cmd Demo [opts] args
157
 
 
 
157
 
158
158
                cmd Demo -h
159
 
 
 
159
 
160
160
            Blah blah blah.
161
161
            """
162
162
        cmd = cmd_Demo()
183
183
 
184
184
    def test_contruct(self):
185
185
        """Construction takes the help topic name for the registered item."""
186
 
        # validate our test 
 
186
        # validate our test
187
187
        self.assertTrue('basic' in help_topics.topic_registry)
188
188
        topic = help_topics.RegisteredTopic('basic')
189
189
        self.assertEqual('basic', topic.topic)