def setUp(self): FileSetup.setUp(self) reset() self.cmd = GPGKeys() self.cmd.preloop() completer.completer = completefilename completer.filename_dequoting_function = print_exc(backslash_dequote_filename) completer.filename_quoting_function = print_exc(backslash_quote_filename)
def setUp(self): FileSetup.setUp(self) reset() self.cmd = Kmd() self.cmd.preloop() completer.completer = completefilename completer.filename_dequoting_function = print_exc(dequote_filename) completer.filename_quoting_function = print_exc(quote_filename)
def setUp(self): FileSetup.setUp(self) reset() self.cmd = Kmd() self.cmd.preloop() completer.completer = completefilename completer.filename_dequoting_function = print_exc(backslash_dequote_filename) completer.filename_quoting_function = print_exc(backslash_quote_filename)
def test_print_exc(self): def complete(text): """Test completer""" return [] p = print_exc(complete) self.assertEqual(p.__name__, 'complete') self.assertEqual(p.__doc__, 'Test completer') self.assertEqual(p('test'), [])