示例#1
0
文件: tests.py 项目: tyrchen/langkawi
 def setup_callback(self, MockFacebook, MockRequest):
     MockRequest.side_effect = get_mock_func(self.get_setup_callback_mock_response)
     MockFacebook.side_effect = get_mock_func(self.get_facebook_data)
     response = self.client.get(self.get_setup_callback_url())
     return response
示例#2
0
文件: tests.py 项目: tyrchen/langkawi
 def callback(self, MockFacebook, MockRequest):
     MockRequest.side_effect = get_mock_func(self.get_callback_mock_response)
     MockFacebook.side_effect = get_mock_func(self.get_facebook_data)
     response = self.client.get(self.get_callback_url(), {"code": "abc"})
     return response