@Test
public void testGetPrimaryLockWithColumn() throws IOException {

  PrimaryLock primary = (PrimaryLock)getLock(COLUMN);
  PrimaryLock actual = ServerLockCleaner.getPrimaryLockWithColumn(primary);
  Assert.assertTrue(primary.equals(actual));
  Assert.assertTrue(COLUMN.equals(actual.getColumn()));
  SecondaryLock secondary = (SecondaryLock)getLock(COLUMN_WITH_ANOTHER_ROW);
  actual = ServerLockCleaner.getPrimaryLockWithColumn(secondary);
  Assert.assertTrue(COLUMN.equals(actual.getColumn()));
  Assert.assertTrue(actual.isPrimary());
  Assert.assertEquals(Type.Minimum, actual.getType());
  Assert.assertEquals(1, actual.getSecondaryColumns().size());
  Assert.assertNotNull(actual.getSecondaryColumns().get(COLUMN_WITH_ANOTHER_ROW));
}