~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_plugins.py

  • Committer: Canonical.com Patch Queue Manager
  • Date: 2011-08-16 09:33:16 UTC
  • mfrom: (6059.3.6 747050-config-help)
  • Revision ID: pqm@pqm.ubuntu.com-20110816093316-favbhalxcbqwxhuw
(vila) Implement per-config option help (Vincent Ladeuil)

Show diffs side-by-side

added added

removed removed

Lines of Context:
615
615
    def test_get_help_text_with_additional_see_also(self):
616
616
        mod = FakeModule('two lines of help\nand more', 'demo')
617
617
        topic = plugin.ModuleHelpTopic(mod)
618
 
        self.assertEqual("two lines of help\nand more\nSee also: bar, foo\n",
619
 
            topic.get_help_text(['foo', 'bar']))
 
618
        self.assertEqual("two lines of help\nand more\n\n:See also: bar, foo\n",
 
619
                         topic.get_help_text(['foo', 'bar']))
620
620
 
621
621
    def test_get_help_topic(self):
622
622
        """The help topic for a plugin is its module name."""
623
623
        mod = FakeModule('two lines of help\nand more', 'bzrlib.plugins.demo')
624
624
        topic = plugin.ModuleHelpTopic(mod)
625
625
        self.assertEqual('demo', topic.get_help_topic())
626
 
        mod = FakeModule('two lines of help\nand more', 'bzrlib.plugins.foo_bar')
 
626
        mod = FakeModule('two lines of help\nand more',
 
627
                         'bzrlib.plugins.foo_bar')
627
628
        topic = plugin.ModuleHelpTopic(mod)
628
629
        self.assertEqual('foo_bar', topic.get_help_topic())
629
630