Package info.archinnov.achilles.internal.metadata.codec

Examples of info.archinnov.achilles.internal.metadata.codec.ListCodec.sourceType()


        Field field = Test.class.getDeclaredField("counts");
        //When
        final ListCodec codec = factory.parseListField(createContext(field));

        //Then
        assertThat(codec.sourceType()).isSameAs(Long.class);
        assertThat(codec.targetType()).isSameAs(String.class);
    }

    @Test
    public void should_create_set_codec() throws Exception {
View Full Code Here


    @Test
    public void should_determine_cql3_list_type() throws Exception {
        //Given
        ListCodec listCodec = mock(ListCodec.class);
        when(listCodec.sourceType()).thenReturn(Integer.class);
        when(listCodec.targetType()).thenReturn(String.class);

        //When
        final Class<?> actualClass = factory.determineCQL3ValueType(listCodec, false);
View Full Code Here

        //When
        final ListCodec actual = parser.parseAndValidateListCodec(Test.class.getDeclaredField("longToString"));

        //Then
        assertThat(actual.sourceType()).isSameAs(Long.class);
        assertThat(actual.targetType()).isSameAs(String.class);
    }

    @Test
    public void should_exception_when_source_type_not_match_for_list_codec() throws Exception {
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.