Search in sources :

Example 16 with StringCodec

use of io.lettuce.core.codec.StringCodec in project lettuce-core by lettuce-io.

the class OutputRegistryUnitTests method streamingTypeOfKeyOuputWithCodecIsAssignableFromString.

@Test
void streamingTypeOfKeyOuputWithCodecIsAssignableFromString() {
    OutputType outputComponentType = OutputRegistry.getStreamingType(KeyListOutput.class);
    ResolvableType resolvableType = outputComponentType.withCodec(new StringCodec());
    assertThat(resolvableType.isAssignableFrom(ResolvableType.forClass(String.class))).isTrue();
}
Also used : StringCodec(io.lettuce.core.codec.StringCodec) ResolvableType(io.lettuce.core.dynamic.support.ResolvableType) Test(org.junit.jupiter.api.Test)

Aggregations

StringCodec (io.lettuce.core.codec.StringCodec)16 Test (org.junit.jupiter.api.Test)12 ResolvableType (io.lettuce.core.dynamic.support.ResolvableType)4 ScanArgs (io.lettuce.core.ScanArgs)1 ScoredValue (io.lettuce.core.ScoredValue)1 SetArgs (io.lettuce.core.SetArgs)1 Timeout (io.lettuce.core.dynamic.domain.Timeout)1 AnnotationCommandSegmentFactory (io.lettuce.core.dynamic.segment.AnnotationCommandSegmentFactory)1 CommandSegments (io.lettuce.core.dynamic.segment.CommandSegments)1 CommandArgs (io.lettuce.core.protocol.CommandArgs)1 Method (java.lang.reflect.Method)1 List (java.util.List)1