[jboss-cvs] JBossAS SVN: r91924 - in projects/mc-tools/grapher/trunk/src: test/java/org/jboss/test/mctools/grapher/graph/test and 1 other directories.

jboss-cvs-commits at lists.jboss.org jboss-cvs-commits at lists.jboss.org
Mon Aug 3 10:08:35 EDT 2009


Author: alesj
Date: 2009-08-03 10:08:35 -0400 (Mon, 03 Aug 2009)
New Revision: 91924

Modified:
   projects/mc-tools/grapher/trunk/src/main/java/org/jboss/mctools/grapher/graph/AbstractGraphCreator.java
   projects/mc-tools/grapher/trunk/src/test/java/org/jboss/test/mctools/grapher/graph/test/GraphCreatorTestCase.java
   projects/mc-tools/grapher/trunk/src/test/resources/org/jboss/test/mctools/grapher/graph/test/GraphCreatorTestCase.xml
Log:
Fix exclude bug.

Modified: projects/mc-tools/grapher/trunk/src/main/java/org/jboss/mctools/grapher/graph/AbstractGraphCreator.java
===================================================================
--- projects/mc-tools/grapher/trunk/src/main/java/org/jboss/mctools/grapher/graph/AbstractGraphCreator.java	2009-08-03 12:25:24 UTC (rev 91923)
+++ projects/mc-tools/grapher/trunk/src/main/java/org/jboss/mctools/grapher/graph/AbstractGraphCreator.java	2009-08-03 14:08:35 UTC (rev 91924)
@@ -178,7 +178,7 @@
             objects.add(edge);
 
             if (dependant != null && doRecurse(dependant))
-               handleContext(controller, dtype, cells, objects, attributes, cs, dependant);
+               handleContext(controller, dtype, cells, objects, attributes, cs, dependant, excludedTypes);
          }
       }
    }

Modified: projects/mc-tools/grapher/trunk/src/test/java/org/jboss/test/mctools/grapher/graph/test/GraphCreatorTestCase.java
===================================================================
--- projects/mc-tools/grapher/trunk/src/test/java/org/jboss/test/mctools/grapher/graph/test/GraphCreatorTestCase.java	2009-08-03 12:25:24 UTC (rev 91923)
+++ projects/mc-tools/grapher/trunk/src/test/java/org/jboss/test/mctools/grapher/graph/test/GraphCreatorTestCase.java	2009-08-03 14:08:35 UTC (rev 91924)
@@ -81,9 +81,9 @@
 
    public void testAll()
    {
-      assertGraphCreator(new AllGraphCreator(), DependencyTypes.IDependOn, 5, 4);
-      assertGraphCreator(new AllGraphCreator(), DependencyTypes.DependsOnMe, 5, 4);
-      assertGraphCreator(new AllGraphCreator(), DependencyTypes.Unresolved, 5, 0);
+      assertGraphCreator(new AllGraphCreator(), DependencyTypes.IDependOn, 8, 6);
+      assertGraphCreator(new AllGraphCreator(), DependencyTypes.DependsOnMe, 7, 5);
+      assertGraphCreator(new AllGraphCreator(), DependencyTypes.Unresolved, 7, 0);
    }
 
    public void testBean()
@@ -132,11 +132,17 @@
       controller.addAlias("ExtAlias", "Owner");
       try
       {
-         assertGraphCreator(new AllGraphCreator(), DependencyTypes.IDependOn, 5, 4, "alias");
+         assertGraphCreator(new AllGraphCreator(), DependencyTypes.IDependOn, 8, 6, "alias");
       }
       finally
       {
          controller.removeAlias("ExtAlias");
       }
    }
+
+   public void testExcludeExtAndCore() throws Throwable
+   {
+      //assertGraphCreator(new BeanGraphCreator("CA"), DependencyTypes.IDependOn, 2, 1, "ext");
+      assertGraphCreator(new TreeGraphCreator("CA"), DependencyTypes.IDependOn, 2, 1, "ext");
+   }
 }

Modified: projects/mc-tools/grapher/trunk/src/test/resources/org/jboss/test/mctools/grapher/graph/test/GraphCreatorTestCase.xml
===================================================================
--- projects/mc-tools/grapher/trunk/src/test/resources/org/jboss/test/mctools/grapher/graph/test/GraphCreatorTestCase.xml	2009-08-03 12:25:24 UTC (rev 91923)
+++ projects/mc-tools/grapher/trunk/src/test/resources/org/jboss/test/mctools/grapher/graph/test/GraphCreatorTestCase.xml	2009-08-03 14:08:35 UTC (rev 91924)
@@ -22,4 +22,12 @@
     <demand>BF1</demand>
   </bean>
 
+  <bean name="CoreAware" class="java.lang.Object">
+    <demand>jboss.kernel:service=Kernel</demand>
+  </bean>
+
+  <bean name="CA" class="java.lang.Object">
+    <demand>CoreAware</demand>
+  </bean>
+
 </deployment>




More information about the jboss-cvs-commits mailing list