@Test
public void getBeanMethods() throws Exception {

    Method expectedGetMethod = Person.class.getMethod("getFirstName");
    Method expectedSetMethod = Person.class.getMethod("setFirstName", String.class);
    // case insensitive
    Method[] methods = ClassUtil.getBeanMethods(InternetPerson.class, "firstname", String.class, false);
    Assert.assertEquals(expectedGetMethod, methods[0]);
    Assert.assertEquals(expectedSetMethod, methods[1]);
    // case sensitive
    methods = ClassUtil.getBeanMethods(InternetPerson.class, "FirstName", String.class, true);
    Assert.assertEquals(expectedGetMethod, methods[0]);
    Assert.assertEquals(expectedSetMethod, methods[1]);
}