Java 类org.springframework.boot.jta.bitronix.PoolingConnectionFactoryBean 实例源码

项目:https-github.com-g0t4-jenkins2-course-spring-boot    文件:JtaAutoConfigurationTests.java   
@Test
public void bitronixConnectionFactoryPoolConfiguration() {
    this.context = new AnnotationConfigApplicationContext();
    EnvironmentTestUtils.addEnvironment(this.context,
            "spring.jta.bitronix.connectionfactory.minPoolSize:5",
            "spring.jta.bitronix.connectionfactory.maxPoolSize:10");
    this.context.register(JtaPropertiesConfiguration.class,
            BitronixJtaConfiguration.class, PoolConfiguration.class);
    this.context.refresh();
    PoolingConnectionFactoryBean connectionFactory = this.context
            .getBean(PoolingConnectionFactoryBean.class);
    assertThat(connectionFactory.getMinPoolSize()).isEqualTo(5);
    assertThat(connectionFactory.getMaxPoolSize()).isEqualTo(10);
}
项目:spring-boot-concourse    文件:JtaAutoConfigurationTests.java   
@Test
public void bitronixConnectionFactoryPoolConfiguration() {
    this.context = new AnnotationConfigApplicationContext();
    EnvironmentTestUtils.addEnvironment(this.context,
            "spring.jta.bitronix.connectionfactory.minPoolSize:5",
            "spring.jta.bitronix.connectionfactory.maxPoolSize:10");
    this.context.register(JtaPropertiesConfiguration.class,
            BitronixJtaConfiguration.class, PoolConfiguration.class);
    this.context.refresh();
    PoolingConnectionFactoryBean connectionFactory = this.context
            .getBean(PoolingConnectionFactoryBean.class);
    assertThat(connectionFactory.getMinPoolSize()).isEqualTo(5);
    assertThat(connectionFactory.getMaxPoolSize()).isEqualTo(10);
}
项目:contestparser    文件:JtaAutoConfigurationTests.java   
@Test
public void bitronixConnectionFactoryPoolConfiguration() {
    this.context = new AnnotationConfigApplicationContext();
    EnvironmentTestUtils.addEnvironment(this.context,
            "spring.jta.bitronix.connectionfactory.minPoolSize:5",
            "spring.jta.bitronix.connectionfactory.maxPoolSize:10");
    this.context.register(JtaPropertiesConfiguration.class,
            BitronixJtaConfiguration.class, PoolConfiguration.class);
    this.context.refresh();
    PoolingConnectionFactoryBean connectionFactory = this.context
            .getBean(PoolingConnectionFactoryBean.class);
    assertThat(connectionFactory.getMinPoolSize(), is(equalTo(5)));
    assertThat(connectionFactory.getMaxPoolSize(), is(equalTo(10)));
}