[jbosstools-issues] [JBoss JIRA] Closed: (JBIDE-9306) Incremental validation doesn't re-validate related alternatives.

Jaroslav Jankovič (JIRA) jira-events at lists.jboss.org
Tue Aug 9 05:37:24 EDT 2011


     [ https://issues.jboss.org/browse/JBIDE-9306?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jaroslav Jankovič closed JBIDE-9306.
------------------------------------



verified on JBoss Developer Studio 5.0.0.v201108060131N-H712-M3

> Incremental validation doesn't re-validate related alternatives.
> ----------------------------------------------------------------
>
>                 Key: JBIDE-9306
>                 URL: https://issues.jboss.org/browse/JBIDE-9306
>             Project: Tools (JBoss Tools)
>          Issue Type: Bug
>          Components: cdi
>    Affects Versions: 3.3.0.M2
>            Reporter: Alexey Kazakov
>            Assignee: Alexey Kazakov
>             Fix For: 3.3.0.M3
>
>
> EXECUTE: Create a CDI project (w/ CDI support enabled)
> EXECUTE: Add the following classes to the project source folder:
> {code}
> package org.jboss;
> import javax.enterprise.inject.Alternative;
> @Alternative
> public class Test {
> }
> {code}
> {code}
> package org.jboss;
> import javax.enterprise.inject.Alternative;
> @Alternative
> public class Test1 extends Test {
> }
> {code}
> {code}
> package org.jboss;
> import javax.inject.Inject;
> public class Test3 {
> 	@Inject Test test;
> }
> {code}
> And beans.xml (should be placed in <source folder>/META-INF/ or <web content>/WEB-INF/ in case of dynamic web project):
> {code}
> <?xml version="1.0" encoding="UTF-8"?>
> <beans xmlns="http://java.sun.com/xml/ns/javaee"
>  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://jboss.org/schema/cdi/beans_1_0.xsd">
> 	<alternatives>
> 		<class>org.jboss.Test1</class>
> 	</alternatives>
> </beans>
> {code}
> EXECUTE: Build the project.
> ASSERT: There is no CDI problem markers on Test3.test field.
> EXECUTE: Replace the beans.xml be the following file:
> {code}
> <?xml version="1.0" encoding="UTF-8"?>
> <beans xmlns="http://java.sun.com/xml/ns/javaee"
>  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://jboss.org/schema/cdi/beans_1_0.xsd">
> </beans>
> {code}
> EXECUTE: Save the file.
> {color:red}FAILURE:{color} The following CDI problem marker doesn't appear on Test3.test field: "No bean is eligible for injection to the injection point [JSR-299 §5.2.1]" 
> {color:green}ASSERT:{color} The following CDI problem marker appears on Test3.test field: "No bean is eligible for injection to the injection point [JSR-299 §5.2.1]"

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

       



More information about the jbosstools-issues mailing list