Created
October 25, 2016 09:53
-
-
Save foxmask/c99447466a3c78f62b3056bf53d36f9a to your computer and use it in GitHub Desktop.
mocker l'appel à __init__ d'une classe
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
with patch('instapush.Instapush') as mock_save_data: | |
with patch('instapush.App') as mock_save_data2: | |
se = ServiceInstapush(self.token) | |
se.save_data(self.trigger_id, **self.data) | |
mock_save_data2.assert_called_once_with(user_token=self.token) | |
mock_save_data.assert_called_once_with(appid='app_id', | |
secret='secret') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment