@Test
public final void testMapperForNullValues() throws IOException, InterruptedException, ConnectionException, AsyncApiException {
Mapper.Context context = mock(Mapper.Context.class);
SFHandler mockSFHandler = mock(SFHandler.class);
when(mockSFHandler.getBulkConnection(anyString(), anyString())).thenReturn(null);
BatchInfo batchInfo = new BatchInfo();
String id = "id";
batchInfo.setId(id);
when(mockSFHandler.createBatch(any(FSDataInputStream.class), any(BulkConnection.class), any(JobInfo.class))).thenReturn(
batchInfo);
ExportSalesforceMapper mapper = new ExportSalesforceMapper();
mapper.setSfHandler(mockSFHandler);
Text batchId = new Text(id);