### Question:
AbstractDubboFilter implements Filter { protected String getResourceName(Invoker<?> invoker, Invocation invocation) { StringBuilder buf = new StringBuilder(64); buf.append(invoker.getInterface().getName()) .append(":") .append(invocation.getMethodName()) .append("("); boolean isFirst = true; for (Class<?> clazz : invocation.getParameterTypes()) { if (!isFirst) { buf.append(","); } buf.append(clazz.getName()); isFirst = false; } buf.append(")"); return buf.toString(); }    }### Answer:
@Test public void testGetResourceName() { Invoker invoker = mock(Invoker.class); when(invoker.getInterface()).thenReturn(DemoService.class); Invocation invocation = mock(Invocation.class); Method method = DemoService.class.getMethods()[0]; when(invocation.getMethodName()).thenReturn(method.getName()); when(invocation.getParameterTypes()).thenReturn(method.getParameterTypes()); String resourceName = filter.getResourceName(invoker, invocation); assertEquals("com.alibaba.csp.sentinel.adapter.dubbo.provider.DemoService:sayHello(java.lang.String,int)", resourceName); }