ShardingSphereDataSourceFactory { public static DataSource createDataSource(final Map<String, DataSource> dataSourceMap, final Collection<RuleConfiguration> configurations, final Properties props) throws SQLException { return new ShardingSphereDataSource(dataSourceMap, configurations, props); }  static DataSource createDataSource(final Map<String, DataSource> dataSourceMap, final Collection<RuleConfiguration> configurations, final Properties props); static DataSource createDataSource(final DataSource dataSource, final Collection<RuleConfiguration> configurations, final Properties props);  }
@Test public void assertCreateDataSourceWithShardingRuleAndProperties() throws SQLException { Properties props = new Properties(); ShardingSphereDataSource dataSource = (ShardingSphereDataSource) ShardingSphereDataSourceFactory.createDataSource( getDataSourceMap(), Collections.singleton(createShardingRuleConfiguration()), props); assertThat(dataSource.getSchemaContexts().getProps().getProps(), is(props)); }