InterceptorMetaDataBean { public List<InterceptorInfo> getMatchingInterceptors(String beanName, Method method) { List<InterceptorInfo> matchingInterceptors = new ArrayList<InterceptorInfo>(); for (InterceptorInfo interceptorInfo : interceptors) { if (interceptorInfo.matches(beanName, method)) { matchingInterceptors.add(interceptorInfo); } } return matchingInterceptors; } InterceptorMetaDataBean(List<InterceptorInfo> interceptors); boolean isInterceptedBean(String beanName); List<InterceptorInfo> getMatchingInterceptors(String beanName, Method method); List<InterceptorInfo> getInterceptors(); void setInterceptors(List<InterceptorInfo> interceptors);  }
@Test public void testGetMatchingInterceptors_beanName() throws SecurityException, NoSuchMethodException { Assert.assertTrue(metaDataBean.getMatchingInterceptors("simple_MyServiceInterface_Impl", this.getClass().getDeclaredMethods()[0]).size()==1); }
@Test public void testGetMatchingInterceptors_methodName() throws SecurityException, NoSuchMethodException { Assert.assertTrue(metaDataBean.getMatchingInterceptors("", Simple_MyServiceInterface_Impl2.class.getDeclaredMethod("sayHello", new Class[]{})).size()==1); }
@Test public void testGetMatchingInterceptors_beanName_negative() throws SecurityException, NoSuchMethodException { Assert.assertTrue(metaDataBean.getMatchingInterceptors("simple_MyServiceInterface_Impl2", this.getClass().getDeclaredMethods()[0]).size()==0); }
@Test public void testGetMatchingInterceptors_methodName_negative() throws SecurityException, NoSuchMethodException { Assert.assertTrue(metaDataBean.getMatchingInterceptors("", Simple_MyServiceInterface_Impl.class.getDeclaredMethod("sayHello", new Class[]{})).size()==1); }