Package org.mongolink.test.simpleMapping

Examples of org.mongolink.test.simpleMapping.CommentMapping


    }

    @Test
    public void canGetConverterForComponent() {
        final MapperContext context = new MapperContext();
        final CommentMapping mapping = new CommentMapping();
        mapping.buildMapper(context);

        final Converter converter = context.converterFor(Comment.class);

        assertThat(converter, notNullValue());
        assertThat(converter, instanceOf(ComponentMapper.class));
View Full Code Here


        return result;
    }

    public PropertyMapper propertyMapperForComponent() throws NoSuchMethodException {
        MapperContext context = new MapperContext();
        CommentMapping mapping = new CommentMapping();
        mapping.buildMapper(context);
        final ClassMapper classMapper = mock(ClassMapper.class);
        when(classMapper.getContext()).thenReturn(context);
        when(classMapper.getPersistentType()).thenReturn(FakeAggregate.class);
        final Method method = FakeAggregate.class.getMethod("getComment", null);
        FieldContainer fieldContainer = new FieldContainer(method);
View Full Code Here

public class TestsComponentMapper {

    @Before
    public void before() throws UnknownHostException {
        CommentMapping commentMapping = new CommentMapping();
        MapperContext context = new MapperContext();
        commentMapping.buildMapper(context);
        mapper = (ComponentMapper<Comment>) context.mapperFor(Comment.class);
    }
View Full Code Here

TOP

Related Classes of org.mongolink.test.simpleMapping.CommentMapping

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.