Search in sources :

Example 1 with TestHintShardingAlgorithm

use of io.shardingjdbc.orchestration.internal.json.fixture.TestHintShardingAlgorithm in project sharding-jdbc by shardingjdbc.

the class ShardingRuleConfigurationConverterTest method assertToJsonForHintStrategy.

@Test
public void assertToJsonForHintStrategy() {
    HintShardingStrategyConfiguration actual = new HintShardingStrategyConfiguration(new TestHintShardingAlgorithm());
    assertThat(ShardingRuleConfigurationConverter.toJson(getCommonShardingRuleConfig(actual)), is(getJsonForHintStrategy()));
}
Also used : HintShardingStrategyConfiguration(io.shardingjdbc.core.api.config.strategy.HintShardingStrategyConfiguration) TestHintShardingAlgorithm(io.shardingjdbc.orchestration.internal.json.fixture.TestHintShardingAlgorithm) Test(org.junit.Test)

Aggregations

HintShardingStrategyConfiguration (io.shardingjdbc.core.api.config.strategy.HintShardingStrategyConfiguration)1 TestHintShardingAlgorithm (io.shardingjdbc.orchestration.internal.json.fixture.TestHintShardingAlgorithm)1 Test (org.junit.Test)1