@Test
public void testShouldSkipPreDMLLogicIfClusterNameColumnDoesNotExist() throws Exception {

  // GIVEN
  reset(dbAccessor);
  Capture<String> tableNameCaptor = newCapture();
  Capture<String> columnNameCaptor = newCapture();
  // the column used by the logic is already deleted
  // this could happen as a result of previously running the update
  expect(dbAccessor.tableHasColumn(capture(tableNameCaptor), capture(columnNameCaptor))).andReturn(false);
  replay(dbAccessor);
  // WHEN
  testSubject.executePreDMLUpdates();
  // THEN
  Assert.assertNotNull("The table name hasn't been captured", tableNameCaptor.getValue());
  Assert.assertEquals("The table name is not as expected", TOPOLOGY_REQUEST_TABLE, tableNameCaptor.getValue());
  Assert.assertNotNull("The column name hasn't been captured", columnNameCaptor.getValue());
  Assert.assertEquals("The column name is not as expected", TOPOLOGY_REQUEST_CLUSTER_NAME_COLUMN,
      columnNameCaptor.getValue());
}