@Test
public void test03() {

    List<String> expectedResult = new ArrayList();
    expectedResult.add("db_index_01.user_0001");
    expectedResult.add("db_index_02.user_0002");
    expectedResult.add("db_index_03.user_0003");
    expectedResult.add("db_index_00.user_0004");
    expectedResult.add("db_index_01.user_0005");
    expectedResult.add("db_index_02.user_0006");
    expectedResult.add("db_index_03.user_0007");
    expectedResult.add("db_index_00.user_0008");
    expectedResult.add("db_index_01.user_0009");
    expectedResult.add("db_index_02.user_0010");
    expectedResult.add("db_index_03.user_0011");
    expectedResult.add("db_index_00.user_0012");
    expectedResult.add("db_index_01.user_0013");
    expectedResult.add("db_index_02.user_0014");
    expectedResult.add("db_index_03.user_0015");
    expectedResult.add("db_index_00.user_0000");
    List<SimpleShardRouteRuleBinding> bindings = new ArrayList<SimpleShardRouteRuleBinding>();
    SpelShardRouteRule strRule = new SpelShardRouteRule("{scName}_{format('%02d', sdValue.hashCode() % 4)}",
                                                        "{tbName}_{format('%04d', sdValue.hashCode() % 16)}");
    SimpleShardRouteRuleBinding user = new SimpleShardRouteRuleBinding();
    user.setScName("db_index");
    user.setTbName("user");
    user.setSdKey("name");
    user.setSdValues("[1..16]");
    user.setRule(strRule);
    bindings.add(user);
    SimpleShardRouter shardRouter = new SimpleShardRouter(bindings);
    List<ShardRouteInfo> routeInfos = shardRouter.getRouteInfos("db_index", "user");
    int count = 0;
    for (ShardRouteInfo si : routeInfos) {
        Assert.equals(si.toString(), expectedResult.get(count));
        count++;
    }
}