Author: akazakov
Date: 2010-03-15 12:28:57 -0400 (Mon, 15 Mar 2010)
New Revision: 20829
Modified:
trunk/cdi/tests/org.jboss.tools.cdi.core.test/src/org/jboss/tools/cdi/core/test/tck/QualifierDefinitionTest.java
Log:
https://jira.jboss.org/jira/browse/JBIDE-5808
Modified:
trunk/cdi/tests/org.jboss.tools.cdi.core.test/src/org/jboss/tools/cdi/core/test/tck/QualifierDefinitionTest.java
===================================================================
---
trunk/cdi/tests/org.jboss.tools.cdi.core.test/src/org/jboss/tools/cdi/core/test/tck/QualifierDefinitionTest.java 2010-03-15
15:37:38 UTC (rev 20828)
+++
trunk/cdi/tests/org.jboss.tools.cdi.core.test/src/org/jboss/tools/cdi/core/test/tck/QualifierDefinitionTest.java 2010-03-15
16:28:57 UTC (rev 20829)
@@ -14,6 +14,7 @@
import org.eclipse.jdt.core.JavaModelException;
import org.jboss.tools.cdi.core.IBean;
+import org.jboss.tools.cdi.core.IInjectionPoint;
import org.jboss.tools.cdi.core.IQualifier;
/**
@@ -36,4 +37,20 @@
assertContainsQualifierType(bean, "javax.enterprise.inject.Default");
assertContainsQualifierType(bean, "javax.enterprise.inject.Any");
}
+
+ /**
+ * section 2.3.1, b)
+ * section 11.1 c)
+ * @throws JavaModelException
+ */
+ public void testDefaultQualifierForInjectionPoint() throws JavaModelException {
+ Set<IBean> beans =
getBeans("org.jboss.jsr299.tck.tests.definition.qualifier.Order");
+ assertEquals("Wrong number of beans with
org.jboss.jsr299.tck.tests.definition.qualifier.Order type.", 1, beans.size());
+ IBean bean = beans.iterator().next();
+ Set<IInjectionPoint> points = bean.getInjectionPoints();
+ IInjectionPoint point = points.iterator().next();
+ Set<IQualifier> qualifiers = bean.getQualifiers();
+ // TODO do we need to care about default qualifiers for InjectionPoint in CDI Tools?
+// assertContainsQualifierType(point, "javax.enterprise.inject.Default");
+ }
}
\ No newline at end of file