@Test
public void testSetPrimaryKeyMap() throws Exception {

    Map map = new HashMap();
    KeyHolder.setPrimaryKey(null, "nullf", map, null);
    Assert.assertNull(map.get("nullf"));
    KeyHolder.setPrimaryKey(JDBCType.BIGINT.getName(), "bif", map, 1);
    Assert.assertEquals(1L, map.get("bif"));
    KeyHolder.setPrimaryKey(JDBCType.INTEGER.getName(), "intf", map, 1);
    Assert.assertEquals(1, map.get("intf"));
    KeyHolder.setPrimaryKey(JDBCType.BINARY.getName(), "binf", map, 1);
    Assert.assertEquals(Byte.valueOf("1"), map.get("binf"));
    KeyHolder.setPrimaryKey(JDBCType.SMALLINT.getName(), "sf", map, 1);
    Assert.assertEquals(Short.valueOf("1"), map.get("sf"));
}