示例#1
0
文件: admin.py 项目: pschwartz/pyhole
    def help(self, message, params=None, **kwargs):
        """Learn how to use active commands (ex: .help <command>)"""

        if params:
            doc = self._find_doc_string(params)
            if doc:
                message.dispatch(doc)
            else:
                message.dispatch("No help available for %s" % params)
        else:
            message.dispatch(self.help.__doc__)
            message.dispatch("Active Commands: %s" % core.active_commands())
            message.dispatch("Active Keywords: %s" % core.active_keywords())
示例#2
0
 def test_active_commands(self):
     self.assertTrue(isinstance(active_commands(), str))
示例#3
0
 def test_active_commands(self):
     self.assertTrue(isinstance(active_commands(), str))