Example #1
0
 def _d(self, *args):
     """Helper for dispatching commands"""
     print args
     cd = CommandDispatch(list(args))
     try:
         cd.execute()
     except SystemExit:
         pass
Example #2
0
 def test_command_dispatch(self):
     
     self._d('tipi')
     self._d('tipi','help')
     self._d('tipi', 'help', 'create')
     self._d('tipi', '--version')
     
     cd = CommandDispatch(['tipi', 'help'])
     #TODO check output
     cd.main_help_text()