@Test
public void convertsComplexGroovyBeanToJson() throws Exception {

    Class<?> aClass = parseGroovyClass("BookStorage.groovy");
    Object groovyObject = aClass.getDeclaredMethod("createBookStorage").invoke(null);
    JsonValue jsonValue = JsonGenerator.createJsonObject(groovyObject);
    assertionHelper.assertThatJsonHasAllFieldsFromObject(groovyObject, jsonValue);
}