@PostMapping
    @Secured(resource = AuthConstants.CONSOLE_RESOURCE_NAME_PREFIX + "roles", action = ActionTypes.WRITE)
    public Object addRole(@RequestParam String role, @RequestParam String username) {
        roleService.addRole(role, username);
        return RestResultUtils.success("add role ok!");
    }
@Test
    void testAddRole() {
        RestResult<String> result = (RestResult<String>) roleController.addRole("test", "nacos");
        
        verify(roleService, times(1)).addRole(anyString(), anyString());
        
        assertEquals(200, result.getCode());
    }