def test_module_args(self): cli = ConsoleCLI([]) cli.parse() res = cli.module_args('copy') self.assertTrue(cli.parser is not None) self.assertIn('src', res) self.assertIn('backup', res) self.assertIsInstance(res, list)
def test_helpdefault(self, mock_display): cli = ConsoleCLI([]) cli.parse() cli.modules = set(['copy']) cli.helpdefault('copy') self.assertTrue(cli.parser is not None) self.assertTrue( len(mock_display.call_args_list) > 0, "display.display should have been called but was not")
def test_helpdefault(self, mock_display): cli = ConsoleCLI([]) cli.parse() cli.modules = set(['copy']) cli.helpdefault('copy') self.assertTrue(cli.parser is not None) self.assertTrue(len(mock_display.call_args_list) > 0, "display.display should have been called but was not")
def test_parse(self): cli = ConsoleCLI([]) cli.parse() self.assertTrue(cli.parser is not None)