### Question:
ShardingValue { public ShardingValueType getType() { if (null != value) { return ShardingValueType.SINGLE; } if (!values.isEmpty()) { return ShardingValueType.LIST; } return ShardingValueType.RANGE; } ShardingValue(final String logicTableName, final String columnName, final T value);  ShardingValue(final String logicTableName, final String columnName, final Collection<T> values);  ShardingValue(final String logicTableName, final String columnName, final Range<T> valueRange); ShardingValueType getType();  }### Answer:
@Test public void assertGetTypeWithSingleValue() { assertThat(new ShardingValue<>("logicTableName", "columnName", "value").getType(), is(ShardingValueType.SINGLE)); }
@Test public void assertGetTypeWithMultipleValue() { assertThat(new ShardingValue<>("logicTableName", "columnName", Collections.singletonList("value")).getType(), is(ShardingValueType.LIST)); }
@Test public void assertGetTypeWithRangeValue() { assertThat(new ShardingValue<>("logicTableName", "columnName", Range.closed(10, 20)).getType(), is(ShardingValueType.RANGE)); }