@GetMapping("")
    public AdminResult<CommonPager<RuleVO>> queryRules(final String selectorId, final String name,
                                                       @RequestParam @NotNull final Integer currentPage,
                                                       @RequestParam @NotNull final Integer pageSize) {
        final RuleQueryCondition condition = new RuleQueryCondition();
        condition.setUserId(SessionUtil.visitor().getUserId());
        condition.setSelectors(ListUtil.of(selectorId));
        condition.setKeyword(name);
        return searchAdaptor(new PageCondition<>(currentPage, pageSize, condition));
    }
@Test
    public void testQueryRules() throws Exception {
        given(this.ruleService.searchByPageToPager(any())).willReturn(commonPager);
        String urlTemplate = "/rule?selectorId={selectorId}&name={name}&currentPage={currentPage}&pageSize={pageSize}";
        this.mockMvc.perform(MockMvcRequestBuilders.get(urlTemplate, "168", "/http/test/**", 1, 12))
                .andExpect(status().isOk())
                .andExpect(jsonPath("$.message", is(ShenyuResultMessage.QUERY_SUCCESS)))
                .andExpect(jsonPath("$.data.dataList[0].id", is(ruleVO.getId())))
                .andReturn();

    }