def test_deprecated_results_warning(self, mock_get): sf = SalesforceAPI('xx', 'xx', 'xx') if PY3: with self.assertWarnsRegex(UserWarning, r'get_batch_results is deprecated'): result_id = sf.get_batch_results('job_id', 'batch_id') else: result_id = sf.get_batch_results('job_id', 'batch_id') self.assertEqual('1234', result_id)
def test_result_ids(self, mock_get): sf = SalesforceAPI('xx', 'xx', 'xx') result_ids = sf.get_batch_result_ids('job_id', 'batch_id') self.assertEqual(['1234', '1235', '1236'], result_ids)
def test_deprecated_results(self, mock_get): sf = SalesforceAPI('xx', 'xx', 'xx') result_id = sf.get_batch_results('job_id', 'batch_id') self.assertEqual('1234', result_id)