[jboss-cvs] JBossAS SVN: r95763 - in projects/metadata/web/trunk/src: test/java/org/jboss/test/metadata/annotation/web and 1 other directories.
jboss-cvs-commits at lists.jboss.org
jboss-cvs-commits at lists.jboss.org
Thu Oct 29 11:24:42 EDT 2009
Author: remy.maucherat at jboss.com
Date: 2009-10-29 11:24:41 -0400 (Thu, 29 Oct 2009)
New Revision: 95763
Modified:
projects/metadata/web/trunk/src/main/java/org/jboss/metadata/annotation/creator/web/WebListenerProcessor.java
projects/metadata/web/trunk/src/test/java/org/jboss/test/metadata/annotation/web/AnnotationWebUnitTestCase.java
projects/metadata/web/trunk/src/test/java/org/jboss/test/metadata/web/WebApp5EverythingUnitTestCase.java
projects/metadata/web/trunk/src/test/java/org/jboss/test/metadata/web/WebApp6EverythingUnitTestCase.java
projects/metadata/web/trunk/src/test/java/org/jboss/test/metadata/web/WebApp6FragmentUnitTestCase.java
Log:
- Drop a number of TODOs. Test cases can always be expanded.
Modified: projects/metadata/web/trunk/src/main/java/org/jboss/metadata/annotation/creator/web/WebListenerProcessor.java
===================================================================
--- projects/metadata/web/trunk/src/main/java/org/jboss/metadata/annotation/creator/web/WebListenerProcessor.java 2009-10-29 14:55:57 UTC (rev 95762)
+++ projects/metadata/web/trunk/src/main/java/org/jboss/metadata/annotation/creator/web/WebListenerProcessor.java 2009-10-29 15:24:41 UTC (rev 95763)
@@ -61,7 +61,6 @@
ListenerMetaData metaData = new ListenerMetaData();
metaData.setListenerClass(element.getName());
- // TODO: description group ?
return metaData;
}
Modified: projects/metadata/web/trunk/src/test/java/org/jboss/test/metadata/annotation/web/AnnotationWebUnitTestCase.java
===================================================================
--- projects/metadata/web/trunk/src/test/java/org/jboss/test/metadata/annotation/web/AnnotationWebUnitTestCase.java 2009-10-29 14:55:57 UTC (rev 95762)
+++ projects/metadata/web/trunk/src/test/java/org/jboss/test/metadata/annotation/web/AnnotationWebUnitTestCase.java 2009-10-29 15:24:41 UTC (rev 95763)
@@ -76,7 +76,6 @@
import org.jboss.metadata.web.jboss.JBossWebMetaData;
import org.jboss.metadata.web.spec.AnnotationMergedView;
import org.jboss.metadata.web.spec.AnnotationMetaData;
-import org.jboss.metadata.web.spec.ServletMetaData;
import org.jboss.metadata.web.spec.Web30MetaData;
import org.jboss.metadata.web.spec.WebMetaData;
import org.jboss.test.metadata.annotation.ws.TestEndpoint;
@@ -161,7 +160,6 @@
assertEquals(2, envEntries.size());
EnvironmentEntryMetaData pi = envEntries.get(MyServlet.class.getName()+ "/pi");
assertEquals("3.14159", pi.getValue());
- // TODO: should this be java.lang.Double?
assertEquals("double", pi.getType());
MessageDestinationReferencesMetaData msgRefs = env.getMessageDestinationReferences();
@@ -380,7 +378,7 @@
//Assert the run as role
JBossServletMetaData jbossServletMetaData = mergedJBossWebMD.getServlets().get("MyServlet");
-// FIXME: Not compatible with 3.0 annotations
+ assertNotNull(jbossServletMetaData);
// assertEquals("InternalUser", jbossServletMetaData.getRunAs().getRoleName());
// assertEquals("javajoe", jbossServletMetaData.getRunAsPrincipal());
@@ -422,10 +420,6 @@
JBossWebMetaData mergedJBossWebMD = new JBossWebMetaData();
mergedJBossWebMD.merge(jbossWMD, xml);
- //Assert the run as role
-// FIXME: Not compatible with 3.0 annotations
-// assertTrue(mergedJBossWebMD.getRunAsIdentity("MyServlet").getRoleName().startsWith("PLACEHOLDER"));
-
WebMetaData merged = new WebMetaData();
//Merge the annotation and xml
AnnotationMergedView.merge(merged, xml, annotation);
@@ -433,12 +427,6 @@
JBossWebMetaData newMerged = new JBossWebMetaData();
newMerged.merge(mergedJBossWebMD, merged);
- //Assert the run as role
-// FIXME: Not compatible with 3.0 annotations
-// JBossServletMetaData jbossServletMetaData = newMerged.getServlets().get("MyServlet");
-// assertEquals("InternalUser", jbossServletMetaData.getRunAs().getRoleName());
-// assertEquals("javajoe", jbossServletMetaData.getRunAsPrincipal());
-
// @PostConstruct
assertEquals("setUp", merged.getPostConstructs().get(0).getMethodName());
// @PreDestroy
Modified: projects/metadata/web/trunk/src/test/java/org/jboss/test/metadata/web/WebApp5EverythingUnitTestCase.java
===================================================================
--- projects/metadata/web/trunk/src/test/java/org/jboss/test/metadata/web/WebApp5EverythingUnitTestCase.java 2009-10-29 14:55:57 UTC (rev 95762)
+++ projects/metadata/web/trunk/src/test/java/org/jboss/test/metadata/web/WebApp5EverythingUnitTestCase.java 2009-10-29 15:24:41 UTC (rev 95763)
@@ -48,7 +48,6 @@
/**
* Test all entries of javaee 5 web-app
- * TODO: still need to add assertions for all elements
*
* @author Scott.Stark at jboss.org
* @author Anil.Saldhana at jboss.com
Modified: projects/metadata/web/trunk/src/test/java/org/jboss/test/metadata/web/WebApp6EverythingUnitTestCase.java
===================================================================
--- projects/metadata/web/trunk/src/test/java/org/jboss/test/metadata/web/WebApp6EverythingUnitTestCase.java 2009-10-29 14:55:57 UTC (rev 95762)
+++ projects/metadata/web/trunk/src/test/java/org/jboss/test/metadata/web/WebApp6EverythingUnitTestCase.java 2009-10-29 15:24:41 UTC (rev 95763)
@@ -53,7 +53,6 @@
/**
* Test all entries of javaee 6 web-app
- * TODO: still need to add assertions for all elements
*
* @author Scott.Stark at jboss.org
* @author Anil.Saldhana at jboss.com
Modified: projects/metadata/web/trunk/src/test/java/org/jboss/test/metadata/web/WebApp6FragmentUnitTestCase.java
===================================================================
--- projects/metadata/web/trunk/src/test/java/org/jboss/test/metadata/web/WebApp6FragmentUnitTestCase.java 2009-10-29 14:55:57 UTC (rev 95762)
+++ projects/metadata/web/trunk/src/test/java/org/jboss/test/metadata/web/WebApp6FragmentUnitTestCase.java 2009-10-29 15:24:41 UTC (rev 95763)
@@ -55,7 +55,6 @@
/**
* Test all entries of javaee 6 web-fragment
- * TODO: still need to add assertions for all elements
*
* @author Scott.Stark at jboss.org
* @author Anil.Saldhana at jboss.com
More information about the jboss-cvs-commits
mailing list