@Override
 public void visitMethod(PsiMethod method) {
   super.visitMethod(method);
   final PsiClass aClass = method.getContainingClass();
   if (TestUtils.isJUnitTestMethod(method)) {
     final PsiPackage[] packages = ClassUtils.calculatePackagesRecursive(aClass);
     for (PsiPackage aPackage : packages) {
       numTestMethodsPerPackage.incrementBucketValue(aPackage, 1);
     }
   }
 }
 public void visitMethod(PsiMethod method) {
   if (methodNestingDepth == 0) {
     elementCount = 0;
   }
   methodNestingDepth++;
   super.visitMethod(method);
   methodNestingDepth--;
   if (methodNestingDepth == 0 && !MethodUtils.isAbstract(method)) {
     postMetric(method, elementCount);
   }
 }
 public void visitMethod(PsiMethod method) {
   super.visitMethod(method);
   if (TestUtils.isJUnitTestMethod(method)) {
     numElements++;
   }
 }