@Test
public void newCachedThreadPool() throws Exception {

    ThreadFactory factory = new NamedThreadFactory("xxx");
    ThreadPoolExecutor executor = ThreadPoolUtils.newCachedThreadPool(10, 20);
    Assert.assertEquals(executor.getCorePoolSize(), 10);
    Assert.assertEquals(executor.getMaximumPoolSize(), 20);
}