@Test(expected = IllegalArgumentException.class)
public void toFunction4() throws Exception {

    Functions.toFunction(new Function4<Integer, Integer, Integer, Integer, Integer>() {
        @Override
        public Integer apply(Integer t1, Integer t2, Integer t3, Integer t4) throws Exception {
            return null;
        }
    }).apply(new Object[20]);
}