コード例 #1
0
 def test_get_data(self, mock_http_request, mock_get):
     """
     test put_data
     """
     mock_get.return_value = "888"
     mock_http_request.return_value = "test"
     esc = client.ESClient("xxx", "xxx")
     self.assertEqual("test", esc.get_data_with_uid("test"))
コード例 #2
0
 def test_get_data_with_condition(self, mock_http_request, mock_get):
     """
     test get_data_with_condition
     """
     mock_get.return_value = "888"
     mock_http_request.return_value = "test"
     esc = client.ESClient("xxx", "xxx")
     self.assertEqual("test", esc.get_data_with_condition({"a": "b"}))
コード例 #3
0
 def test_init(self, mock_get):
     """
     test init
     """
     mock_get.return_value = "888"
     esc = client.ESClient("xxx", "xxx")