def test_get_field_mapping(self): """get_field_mapping returns the mapping reported by Elasticsearch.""" with patch.object(IndicesClient, "get_field_mapping") as gfm: gfm.return_value = "pass me through" result = DailyIndexDocType.get_field_mapping("field") self.assertEqual(result, "pass me through")
def test_get_field_mapping(self): """get_field_mapping returns the mapping reported by Elasticsearch.""" with patch.object(IndicesClient, "get_field_mapping") as gfm: gfm.return_value = 'pass me through' result = DailyIndexDocType.get_field_mapping('field') self.assertEqual(result, 'pass me through')