Exemple #1
0
 def test_start_with_client(self):
     arguments = MockArgumentParser()
     TelegramBotClient.TELEGRAM_CLIENT = MockTelegramBotClient(arguments)
     mock_bot = unittest.mock.Mock()
     update = []
     start(mock_bot, update)
Exemple #2
0
 def test_start_with_client(self):
     arguments = MockArgumentParser()
     TelegramBotClient.TELEGRAM_CLIENT = MockTelegramBotClient(arguments)
     mock_bot = unittest.mock.Mock()
     update = []
     start(mock_bot, update)
Exemple #3
0
 def test_start_no_client(self):
     TelegramBotClient.TELEGRAM_CLIENT = None
     mock_bot = unittest.mock.Mock()
     update = []
     with self.assertRaises(Exception):
         start(mock_bot, update)
Exemple #4
0
 def test_start_no_client(self):
     TelegramBotClient.TELEGRAM_CLIENT = None
     mock_bot = unittest.mock.Mock()
     update = []
     with self.assertRaises(Exception):
         start(mock_bot, update)