// Path: src/main/java/com/hyperwallet/clientsdk/util/HyperwalletJsonConfiguration.java
// public class HyperwalletJsonConfiguration {
// 
//     public static final String INCLUSION_FILTER = "inclusion-filter";
//     private ObjectMapper objectMapper;
//     private ObjectMapper parsingObjectMapper;
// 
//     HyperwalletJsonConfiguration() {
//         DateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss");
//         dateFormat.setTimeZone(TimeZone.getTimeZone("UTC"));
// 
//         this.objectMapper = new ObjectMapper()
//                 .configure(JsonParser.Feature.ALLOW_SINGLE_QUOTES, true)
//                 .configure(JsonParser.Feature.ALLOW_UNQUOTED_FIELD_NAMES, true)
//                 .configure(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES, false)
//                 .disable(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES)
//                 .configure(MapperFeature.SORT_PROPERTIES_ALPHABETICALLY, true)
//                 .configure(SerializationFeature.WRITE_NULL_MAP_VALUES, false)
//                 .configure(SerializationFeature.WRITE_ENUMS_USING_INDEX, false)
//                 .setDateFormat(dateFormat)
//                 .setSerializationInclusion(Include.ALWAYS);
// 
//         this.parsingObjectMapper = new ObjectMapper()
//                 .configure(JsonParser.Feature.ALLOW_SINGLE_QUOTES, true)
//                 .configure(JsonParser.Feature.ALLOW_UNQUOTED_FIELD_NAMES, true)
//                 .configure(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES, false)
//                 .disable(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES)
//                 .configure(MapperFeature.SORT_PROPERTIES_ALPHABETICALLY, true)
//                 .configure(SerializationFeature.WRITE_NULL_MAP_VALUES, false)
//                 .configure(SerializationFeature.WRITE_EMPTY_JSON_ARRAYS, false)
//                 .configure(SerializationFeature.WRITE_ENUMS_USING_INDEX, false);
//     }
// 
//     public ObjectMapper getParser() {
//         return this.parsingObjectMapper;
//     }
// 
//     public ObjectMapper getContext(final Class<?> type) {
//         return objectMapper;
//     }
// 
// 
// }


import com.fasterxml.jackson.annotation.JsonFilter;
import com.hyperwallet.clientsdk.util.HyperwalletJsonConfiguration;
import org.hamcrest.Matchers;
import org.testng.annotations.BeforeMethod;
import org.testng.annotations.DataProvider;
import org.testng.annotations.Test;
import java.lang.reflect.Field;
import java.lang.reflect.Method;
import java.lang.reflect.Modifier;
import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;
import static org.hamcrest.MatcherAssert.assertThat;
import static org.hamcrest.Matchers.*;
import static org.testng.Assert.fail;
package com.hyperwallet.clientsdk.model;





/**
 * @author fkrauthan
 */
public abstract class BaseModelTest<T> {

    private T baseModel;
    private List<String> fieldNames;

    @BeforeMethod
    public void setUp() {
        this.baseModel = createBaseModel();
        this.fieldNames = collectFieldNames();
    }

    protected abstract T createBaseModel();

    protected abstract Class<T> createModelClass();

    @Test
    public void testJsonFilterAnnotationPresent() throws Exception {
        Class<T> clazz = createModelClass();
        T model = clazz.newInstance();

        if (model instanceof HyperwalletBaseMonitor) {
            JsonFilter filter = clazz.getAnnotation(JsonFilter.class);
            assertThat(filter, is(notNullValue()));
// Path: src/main/java/com/hyperwallet/clientsdk/util/HyperwalletJsonConfiguration.java
// public class HyperwalletJsonConfiguration {
// 
//     public static final String INCLUSION_FILTER = "inclusion-filter";
//     private ObjectMapper objectMapper;
//     private ObjectMapper parsingObjectMapper;
// 
//     HyperwalletJsonConfiguration() {
//         DateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss");
//         dateFormat.setTimeZone(TimeZone.getTimeZone("UTC"));
// 
//         this.objectMapper = new ObjectMapper()
//                 .configure(JsonParser.Feature.ALLOW_SINGLE_QUOTES, true)
//                 .configure(JsonParser.Feature.ALLOW_UNQUOTED_FIELD_NAMES, true)
//                 .configure(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES, false)
//                 .disable(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES)
//                 .configure(MapperFeature.SORT_PROPERTIES_ALPHABETICALLY, true)
//                 .configure(SerializationFeature.WRITE_NULL_MAP_VALUES, false)
//                 .configure(SerializationFeature.WRITE_ENUMS_USING_INDEX, false)
//                 .setDateFormat(dateFormat)
//                 .setSerializationInclusion(Include.ALWAYS);
// 
//         this.parsingObjectMapper = new ObjectMapper()
//                 .configure(JsonParser.Feature.ALLOW_SINGLE_QUOTES, true)
//                 .configure(JsonParser.Feature.ALLOW_UNQUOTED_FIELD_NAMES, true)
//                 .configure(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES, false)
//                 .disable(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES)
//                 .configure(MapperFeature.SORT_PROPERTIES_ALPHABETICALLY, true)
//                 .configure(SerializationFeature.WRITE_NULL_MAP_VALUES, false)
//                 .configure(SerializationFeature.WRITE_EMPTY_JSON_ARRAYS, false)
//                 .configure(SerializationFeature.WRITE_ENUMS_USING_INDEX, false);
//     }
// 
//     public ObjectMapper getParser() {
//         return this.parsingObjectMapper;
//     }
// 
//     public ObjectMapper getContext(final Class<?> type) {
//         return objectMapper;
//     }
// 
// 
// }


// Path: src/test/java/com/hyperwallet/clientsdk/model/BaseModelTest.java
import com.fasterxml.jackson.annotation.JsonFilter;
import com.hyperwallet.clientsdk.util.HyperwalletJsonConfiguration;
import org.hamcrest.Matchers;
import org.testng.annotations.BeforeMethod;
import org.testng.annotations.DataProvider;
import org.testng.annotations.Test;
import java.lang.reflect.Field;
import java.lang.reflect.Method;
import java.lang.reflect.Modifier;
import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;
import static org.hamcrest.MatcherAssert.assertThat;
import static org.hamcrest.Matchers.*;
import static org.testng.Assert.fail;

package com.hyperwallet.clientsdk.model;





/**
 * @author fkrauthan
 */
public abstract class BaseModelTest<T> {

    private T baseModel;
    private List<String> fieldNames;

    @BeforeMethod
    public void setUp() {
        this.baseModel = createBaseModel();
        this.fieldNames = collectFieldNames();
    }

    protected abstract T createBaseModel();

    protected abstract Class<T> createModelClass();

    @Test
    public void testJsonFilterAnnotationPresent() throws Exception {
        Class<T> clazz = createModelClass();
        T model = clazz.newInstance();

        if (model instanceof HyperwalletBaseMonitor) {
            JsonFilter filter = clazz.getAnnotation(JsonFilter.class);
            assertThat(filter, is(notNullValue()));
            assertThat(filter.value(), is(equalTo(HyperwalletJsonConfiguration.INCLUSION_FILTER)));