private boolean spansMultipleModules() {
   final String qualifiedName = getConfiguration().getPackage();
   if (qualifiedName != null) {
     final Project project = getConfiguration().getProject();
     final PsiPackage aPackage = JavaPsiFacade.getInstance(project).findPackage(qualifiedName);
     if (aPackage != null) {
       final TestSearchScope scope = getScope();
       if (scope != null) {
         final SourceScope sourceScope = scope.getSourceScope(getConfiguration());
         if (sourceScope != null) {
           final GlobalSearchScope configurationSearchScope =
               GlobalSearchScopesCore.projectTestScope(project)
                   .intersectWith(sourceScope.getGlobalSearchScope());
           final PsiDirectory[] directories = aPackage.getDirectories(configurationSearchScope);
           return directories.length > 1;
         }
       }
     }
   }
   return false;
 }
 public SourceScope getSourceScope() {
   return SourceScope.modulesWithDependencies(myConfiguration.getModules());
 }
 public Module[] getModulesToCompile() {
   final SourceScope sourceScope = getSourceScope();
   return sourceScope != null ? sourceScope.getModulesToCompile() : Module.EMPTY_ARRAY;
 }