Java 类org.springframework.boot.configurationsample.simple.SimpleCollectionProperties 实例源码

项目:https-github.com-g0t4-jenkins2-course-spring-boot    文件:ConfigurationMetadataAnnotationProcessorTests.java   
@Test
public void parseCollectionConfig() throws Exception {
    ConfigurationMetadata metadata = compile(SimpleCollectionProperties.class);
    // getter and setter
    assertThat(metadata).has(Metadata.withProperty("collection.integers-to-names",
            "java.util.Map<java.lang.Integer,java.lang.String>"));
    assertThat(metadata).has(Metadata.withProperty("collection.longs",
            "java.util.Collection<java.lang.Long>"));
    assertThat(metadata).has(Metadata.withProperty("collection.floats",
            "java.util.List<java.lang.Float>"));
    // getter only
    assertThat(metadata).has(Metadata.withProperty("collection.names-to-integers",
            "java.util.Map<java.lang.String,java.lang.Integer>"));
    assertThat(metadata).has(Metadata.withProperty("collection.bytes",
            "java.util.Collection<java.lang.Byte>"));
    assertThat(metadata).has(Metadata.withProperty("collection.doubles",
            "java.util.List<java.lang.Double>"));
}
项目:spring-boot-concourse    文件:ConfigurationMetadataAnnotationProcessorTests.java   
@Test
public void parseCollectionConfig() throws Exception {
    ConfigurationMetadata metadata = compile(SimpleCollectionProperties.class);
    // getter and setter
    assertThat(metadata).has(Metadata.withProperty("collection.integers-to-names",
            "java.util.Map<java.lang.Integer,java.lang.String>"));
    assertThat(metadata).has(Metadata.withProperty("collection.longs",
            "java.util.Collection<java.lang.Long>"));
    assertThat(metadata).has(Metadata.withProperty("collection.floats",
            "java.util.List<java.lang.Float>"));
    // getter only
    assertThat(metadata).has(Metadata.withProperty("collection.names-to-integers",
            "java.util.Map<java.lang.String,java.lang.Integer>"));
    assertThat(metadata).has(Metadata.withProperty("collection.bytes",
            "java.util.Collection<java.lang.Byte>"));
    assertThat(metadata).has(Metadata.withProperty("collection.doubles",
            "java.util.List<java.lang.Double>"));
}
项目:contestparser    文件:ConfigurationMetadataAnnotationProcessorTests.java   
@Test
public void parseCollectionConfig() throws Exception {
    ConfigurationMetadata metadata = compile(SimpleCollectionProperties.class);
    // getter and setter
    assertThat(metadata, containsProperty("collection.integers-to-names",
            "java.util.Map<java.lang.Integer,java.lang.String>"));
    assertThat(metadata, containsProperty("collection.longs",
            "java.util.Collection<java.lang.Long>"));
    assertThat(metadata,
            containsProperty("collection.floats", "java.util.List<java.lang.Float>"));
    // getter only
    assertThat(metadata, containsProperty("collection.names-to-integers",
            "java.util.Map<java.lang.String,java.lang.Integer>"));
    assertThat(metadata, containsProperty("collection.bytes",
            "java.util.Collection<java.lang.Byte>"));
    assertThat(metadata, containsProperty("collection.doubles",
            "java.util.List<java.lang.Double>"));
}