diff --git a/sharding-core/src/test/java/io/shardingsphere/core/keygen/DefaultKeyGeneratorTest.java b/sharding-core/src/test/java/io/shardingsphere/core/keygen/DefaultKeyGeneratorTest.java index 83c58124a448978a4df5a6e347c917f0d422ff9c..7efee4ce0744db358dff24857cccaa7472aeed46 100644 --- a/sharding-core/src/test/java/io/shardingsphere/core/keygen/DefaultKeyGeneratorTest.java +++ b/sharding-core/src/test/java/io/shardingsphere/core/keygen/DefaultKeyGeneratorTest.java @@ -17,8 +17,6 @@ package io.shardingsphere.core.keygen; -import io.shardingsphere.core.constant.properties.ShardingProperties; -import io.shardingsphere.core.constant.properties.ShardingPropertiesConstant; import io.shardingsphere.core.keygen.fixture.FixedTimeService; import lombok.SneakyThrows; import org.junit.Test; @@ -169,7 +167,7 @@ public final class DefaultKeyGeneratorTest { keyGenerator.setProperties(properties); Field props = keyGenerator.getClass().getDeclaredField("properties"); props.setAccessible(true); - assertThat(((ShardingProperties) props.get(keyGenerator)).getValue(ShardingPropertiesConstant.WORK_ID), is((Object) 1L)); + assertThat(((Properties) props.get(keyGenerator)).get("work.id"), is((Object) 1L)); } @Test @@ -181,6 +179,6 @@ public final class DefaultKeyGeneratorTest { keyGenerator.setProperties(properties); Field props = keyGenerator.getClass().getDeclaredField("properties"); props.setAccessible(true); - assertThat(((ShardingProperties) props.get(keyGenerator)).getValue(ShardingPropertiesConstant.MAX_TOLERATE_TIME_DIFFERENCE_MILLISECONDS), is((Object) 1)); + assertThat(((Properties) props.get(keyGenerator)).get("max.tolerate.time.difference.milliseconds"), is((Object) 1)); } }