Author: nickarls
Date: 2009-12-10 06:44:51 -0500 (Thu, 10 Dec 2009)
New Revision: 5265
Added:
core/trunk/tests/src/test/java/org/jboss/weld/tests/unit/bootstrap/xml/
core/trunk/tests/src/test/java/org/jboss/weld/tests/unit/bootstrap/xml/Alt.java
core/trunk/tests/src/test/java/org/jboss/weld/tests/unit/bootstrap/xml/BeansXmlTest.java
core/trunk/tests/src/test/java/org/jboss/weld/tests/unit/bootstrap/xml/Dec.java
core/trunk/tests/src/test/java/org/jboss/weld/tests/unit/bootstrap/xml/Int.java
core/trunk/tests/src/test/java/org/jboss/weld/tests/unit/bootstrap/xml/IntBind.java
core/trunk/tests/src/test/java/org/jboss/weld/tests/unit/bootstrap/xml/Plain.java
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/alternative.xml
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/decorator.xml
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/interceptor.xml
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/multipleAlternativeBlocks.xml
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/multipleDecoratorBlocks.xml
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/multipleInterceptorsBlocks.xml
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/unloadable.xml
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/unparseable.xml
Modified:
core/trunk/impl/src/main/java/org/jboss/weld/xml/BeansXmlElement.java
core/trunk/impl/src/main/java/org/jboss/weld/xml/BeansXmlParser.java
core/trunk/impl/src/main/java/org/jboss/weld/xml/EnabledClasses.java
core/trunk/impl/src/main/java/org/jboss/weld/xml/MergedElements.java
core/trunk/impl/src/main/resources/org/jboss/weld/messages/xml_en.properties
core/trunk/tests/src/test/java/org/jboss/weld/tests/enterprise/EnterpriseBeanTest.java
Log:
Part I of tests for WELD-319 (parsing part)
Delegate validation to Validator
Missing parser message
Typo in test JIRA reference
Modified: core/trunk/impl/src/main/java/org/jboss/weld/xml/BeansXmlElement.java
===================================================================
--- core/trunk/impl/src/main/java/org/jboss/weld/xml/BeansXmlElement.java 2009-12-10
09:25:26 UTC (rev 5264)
+++ core/trunk/impl/src/main/java/org/jboss/weld/xml/BeansXmlElement.java 2009-12-10
11:44:51 UTC (rev 5265)
@@ -22,8 +22,6 @@
import java.util.ArrayList;
import java.util.List;
-import org.jboss.weld.DeploymentException;
-import org.jboss.weld.logging.messages.XmlMessage;
import org.jboss.weld.resources.spi.ResourceLoader;
import org.jboss.weld.resources.spi.ResourceLoadingException;
import org.jboss.weld.util.dom.NodeListIterable;
@@ -40,34 +38,14 @@
{
private URL file;
private Element element;
- private List<String> classNames;
private BeansXmlElement(URL file, Element element)
{
super();
this.file = file;
this.element = element;
- classNames = new ArrayList<String>();
}
- public BeansXmlElement validateWithMessage(XmlMessage multipleViolationMessage)
- {
- for (Node child : new NodeListIterable(element.getChildNodes()))
- {
- String className = getClassNameFromNode(child);
- if (className == null)
- {
- continue;
- }
- if (classNames.contains(className))
- {
- throw new DeploymentException(multipleViolationMessage);
- }
- classNames.add(className);
- }
- return this;
- }
-
private String getClassNameFromNode(Node node)
{
if (node instanceof Element)
@@ -89,15 +67,20 @@
public List<Class<?>> getClasses(ResourceLoader resourceLoader)
{
List<Class<?>> classes = new ArrayList<Class<?>>();
- for (String className : classNames)
+ for (Node child : new NodeListIterable(element.getChildNodes()))
{
+ String className = getClassNameFromNode(child);
+ if (className == null)
+ {
+ continue;
+ }
try
{
classes.add(resourceLoader.classForName(className));
}
catch (ResourceLoadingException e)
{
- throw new DeploymentException(CANNOT_LOAD_CLASS, className, file);
+ throw new WeldXmlException(CANNOT_LOAD_CLASS, className, file);
}
}
return classes;
Modified: core/trunk/impl/src/main/java/org/jboss/weld/xml/BeansXmlParser.java
===================================================================
--- core/trunk/impl/src/main/java/org/jboss/weld/xml/BeansXmlParser.java 2009-12-10
09:25:26 UTC (rev 5264)
+++ core/trunk/impl/src/main/java/org/jboss/weld/xml/BeansXmlParser.java 2009-12-10
11:44:51 UTC (rev 5265)
@@ -30,7 +30,6 @@
import javax.xml.parsers.DocumentBuilderFactory;
import javax.xml.parsers.ParserConfigurationException;
-import org.jboss.weld.DeploymentException;
import org.jboss.weld.resources.spi.ResourceLoader;
import org.w3c.dom.Document;
import org.xml.sax.SAXException;
@@ -102,11 +101,11 @@
}
catch (SAXException e)
{
- throw new DeploymentException(PARSING_ERROR, e, beansXml.toString());
+ throw new WeldXmlException(PARSING_ERROR, e, beansXml.toString());
}
catch (IOException e)
{
- throw new DeploymentException(LOAD_ERROR, e, beansXml.toString());
+ throw new WeldXmlException(LOAD_ERROR, e, beansXml.toString());
}
finally
{
@@ -133,6 +132,10 @@
private boolean isBeansXmlOK(URL beansXml)
{
+ if (beansXml == null)
+ {
+ throw new WeldXmlException(LOAD_ERROR, "null-URL");
+ }
InputStream in = null;
try
{
Modified: core/trunk/impl/src/main/java/org/jboss/weld/xml/EnabledClasses.java
===================================================================
--- core/trunk/impl/src/main/java/org/jboss/weld/xml/EnabledClasses.java 2009-12-10
09:25:26 UTC (rev 5264)
+++ core/trunk/impl/src/main/java/org/jboss/weld/xml/EnabledClasses.java 2009-12-10
11:44:51 UTC (rev 5265)
@@ -19,7 +19,6 @@
import java.lang.annotation.Annotation;
import java.util.ArrayList;
import java.util.Collection;
-import java.util.LinkedHashSet;
import java.util.List;
import org.jboss.weld.resources.spi.ResourceLoader;
@@ -73,7 +72,7 @@
private Collection<Class<?>>
getClassesInElements(List<BeansXmlElement> elements)
{
- LinkedHashSet<Class<?>> classes = new
LinkedHashSet<Class<?>>();
+ List<Class<?>> classes = new ArrayList<Class<?>>();
for (BeansXmlElement element : elements)
{
classes.addAll(element.getClasses(resourceLoader));
Modified: core/trunk/impl/src/main/java/org/jboss/weld/xml/MergedElements.java
===================================================================
--- core/trunk/impl/src/main/java/org/jboss/weld/xml/MergedElements.java 2009-12-10
09:25:26 UTC (rev 5264)
+++ core/trunk/impl/src/main/java/org/jboss/weld/xml/MergedElements.java 2009-12-10
11:44:51 UTC (rev 5265)
@@ -24,7 +24,6 @@
import java.util.ArrayList;
import java.util.List;
-import org.jboss.weld.DeploymentException;
import org.jboss.weld.logging.messages.XmlMessage;
import org.w3c.dom.Document;
import org.w3c.dom.Element;
@@ -50,19 +49,17 @@
decoratorsElements.addAll(getNamedElement(url, documentElement,
"decorators", MULTIPLE_DECORATORS));
}
- // TODO: look over exception message when multiple blocks or multiple
- // classes. Now they're the same.
private List<BeansXmlElement> getNamedElement(URL url, Element beans, String
name, XmlMessage multipleViolationMessage)
{
List<BeansXmlElement> elements = new ArrayList<BeansXmlElement>();
NodeList nodeList = beans.getElementsByTagName(name);
if (nodeList.getLength() > 1)
{
- throw new DeploymentException(multipleViolationMessage);
+ throw new WeldXmlException(multipleViolationMessage);
}
else if (nodeList.getLength() == 1)
{
- BeansXmlElement element = BeansXmlElement.of(url,
nodeList.item(0)).validateWithMessage(multipleViolationMessage);
+ BeansXmlElement element = BeansXmlElement.of(url, nodeList.item(0));
elements.add(element);
}
return elements;
Modified: core/trunk/impl/src/main/resources/org/jboss/weld/messages/xml_en.properties
===================================================================
---
core/trunk/impl/src/main/resources/org/jboss/weld/messages/xml_en.properties 2009-12-10
09:25:26 UTC (rev 5264)
+++
core/trunk/impl/src/main/resources/org/jboss/weld/messages/xml_en.properties 2009-12-10
11:44:51 UTC (rev 5265)
@@ -1,6 +1,7 @@
CONFIGURATION_ERROR=Error configuring XML parser
-LOAD_ERROR=Error loading {0}
+LOAD_ERROR=Error loading beans.xml {0}
+CANNOT_LOAD_CLASS=Could not load class {0}
PARSING_ERROR=Error parsing {0}
MULTIPLE_ALTERNATIVES=<alternatives> can only be specified once, but appears
multiple times\: {0}
-MULTIPLE_DECORATORS=<decorator> can only be specified once, but is specified
multiple times\: {0}
+MULTIPLE_DECORATORS=<decorators> can only be specified once, but is specified
multiple times\: {0}
MULTIPLE_INTERCEPTORS=<interceptor> can only be specified once, but it is specified
multiple times\: {0}
Modified:
core/trunk/tests/src/test/java/org/jboss/weld/tests/enterprise/EnterpriseBeanTest.java
===================================================================
---
core/trunk/tests/src/test/java/org/jboss/weld/tests/enterprise/EnterpriseBeanTest.java 2009-12-10
09:25:26 UTC (rev 5264)
+++
core/trunk/tests/src/test/java/org/jboss/weld/tests/enterprise/EnterpriseBeanTest.java 2009-12-10
11:44:51 UTC (rev 5265)
@@ -21,7 +21,7 @@
}
- @Test(description="WBRI-326")
+ @Test(description="WELD-326")
public void testInvocationExceptionIsUnwrapped()
{
try
Added: core/trunk/tests/src/test/java/org/jboss/weld/tests/unit/bootstrap/xml/Alt.java
===================================================================
--- core/trunk/tests/src/test/java/org/jboss/weld/tests/unit/bootstrap/xml/Alt.java
(rev 0)
+++
core/trunk/tests/src/test/java/org/jboss/weld/tests/unit/bootstrap/xml/Alt.java 2009-12-10
11:44:51 UTC (rev 5265)
@@ -0,0 +1,9 @@
+package org.jboss.weld.tests.unit.bootstrap.xml;
+
+import javax.enterprise.inject.Alternative;
+
+@Alternative
+public class Alt
+{
+
+}
Added:
core/trunk/tests/src/test/java/org/jboss/weld/tests/unit/bootstrap/xml/BeansXmlTest.java
===================================================================
---
core/trunk/tests/src/test/java/org/jboss/weld/tests/unit/bootstrap/xml/BeansXmlTest.java
(rev 0)
+++
core/trunk/tests/src/test/java/org/jboss/weld/tests/unit/bootstrap/xml/BeansXmlTest.java 2009-12-10
11:44:51 UTC (rev 5265)
@@ -0,0 +1,169 @@
+package org.jboss.weld.tests.unit.bootstrap.xml;
+
+import java.net.MalformedURLException;
+import java.net.URL;
+import java.util.Arrays;
+import java.util.Collections;
+import java.util.List;
+
+import org.jboss.weld.logging.messages.XmlMessage;
+import org.jboss.weld.mock.MockEELifecycle;
+import org.jboss.weld.mock.TestContainer;
+import org.jboss.weld.xml.WeldXmlException;
+import org.testng.annotations.Test;
+
+@SuppressWarnings("unchecked")
+public class BeansXmlTest
+{
+ private class FailedDeployment
+ {
+ private List<Class<?>> beans = Collections.emptyList();
+ private List<URL> beansXml = Collections.emptyList();
+
+ public FailedDeployment(List<Class<?>> beans, List<URL>
beansXml)
+ {
+ this.beans = beans;
+ this.beansXml = beansXml;
+ }
+
+ public void run()
+ {
+ TestContainer container = null;
+ try
+ {
+ container = new TestContainer(new MockEELifecycle(), beans,
beansXml).startContainer().ensureRequestActive();
+ }
+ finally
+ {
+ if (container != null)
+ {
+ container.stopContainer();
+ }
+ }
+ }
+
+ public void runAndExpect(WeldXmlException expected)
+ {
+ String errorCode = expected.getMessage().substring(0, 12);
+ try
+ {
+ run();
+ }
+ catch (WeldXmlException e)
+ {
+ if (e.getMessage().startsWith(errorCode))
+ {
+ return;
+ }
+ }
+ assert false;
+ }
+
+ }
+
+ private void testWithBeansXmlAndExpectException(String beansXml, WeldXmlException e)
+ {
+ List<Class<?>> beans = Arrays.asList(Alt.class, Dec.class, Int.class,
Plain.class, IntBind.class);
+ List<URL> beansXmls = Arrays.asList(getClass().getResource(beansXml));
+ new FailedDeployment(beans, beansXmls).runAndExpect(e);
+ }
+
+ // Multiple XML blocks
+
+ @Test
+ public void multipleAlternativeBlocksFail()
+ {
+ testWithBeansXmlAndExpectException("multipleAlternativeBlocks.xml", new
WeldXmlException(XmlMessage.MULTIPLE_ALTERNATIVES));
+ }
+
+ @Test
+ public void multipleDecoratorBlocksFail()
+ {
+ testWithBeansXmlAndExpectException("multipleDecoratorBlocks.xml", new
WeldXmlException(XmlMessage.MULTIPLE_DECORATORS));
+ }
+
+ @Test
+ public void multipleInterceptorBlocksFail()
+ {
+ testWithBeansXmlAndExpectException("multipleInterceptorsBlocks.xml", new
WeldXmlException(XmlMessage.MULTIPLE_INTERCEPTORS));
+ }
+
+ @Test
+ public void alternativesEnabled()
+ {
+ List<Class<?>> beans = Arrays.asList(Alt.class, Dec.class, Int.class,
IntBind.class, Plain.class);
+ List<URL> beansXmls =
Arrays.asList(getClass().getResource("alternative.xml"));
+ TestContainer container = new TestContainer(new MockEELifecycle(), beans,
beansXmls).startContainer().ensureRequestActive();
+ assert container.getBeanManager().getEnabledAlternativeClasses().size() == 1;
+ assert container.getBeanManager().getEnabledAlternativeClasses().iterator().next()
== Alt.class;
+ container.stopContainer();
+ }
+
+ @Test
+ public void decoratorsEnabled()
+ {
+ List<Class<?>> beans = Arrays.asList(Alt.class, Dec.class, Int.class,
IntBind.class, Plain.class);
+ List<URL> beansXmls =
Arrays.asList(getClass().getResource("decorator.xml"));
+ TestContainer container = new TestContainer(new MockEELifecycle(), beans,
beansXmls).startContainer().ensureRequestActive();
+ assert container.getBeanManager().getEnabledDecoratorClasses().size() == 1;
+ assert container.getBeanManager().getEnabledDecoratorClasses().iterator().next() ==
Dec.class;
+ container.stopContainer();
+ }
+
+ @Test
+ public void interceptorsEnabled()
+ {
+ List<Class<?>> beans = Arrays.asList(Alt.class, Dec.class, Int.class,
IntBind.class, Plain.class);
+ List<URL> beansXmls =
Arrays.asList(getClass().getResource("interceptor.xml"));
+ TestContainer container = new TestContainer(new MockEELifecycle(), beans,
beansXmls).startContainer().ensureRequestActive();
+ assert container.getBeanManager().getEnabledInterceptorClasses().size() == 1;
+ assert container.getBeanManager().getEnabledInterceptorClasses().iterator().next()
== Int.class;
+ container.stopContainer();
+ }
+
+ @Test
+ public void testMergeBeansXmls()
+ {
+ List<Class<?>> beans = Arrays.asList(Alt.class, Dec.class, Int.class,
IntBind.class, Plain.class);
+ List<URL> beansXmls =
Arrays.asList(getClass().getResource("alternative.xml"),
getClass().getResource("decorator.xml"),
getClass().getResource("interceptor.xml"));
+ TestContainer container = new TestContainer(new MockEELifecycle(), beans,
beansXmls).startContainer().ensureRequestActive();
+ assert container.getBeanManager().getEnabledAlternativeClasses().size() == 1;
+ assert container.getBeanManager().getEnabledAlternativeClasses().iterator().next()
== Alt.class;
+ assert container.getBeanManager().getEnabledInterceptorClasses().size() == 1;
+ assert container.getBeanManager().getEnabledInterceptorClasses().iterator().next()
== Int.class;
+ assert container.getBeanManager().getEnabledDecoratorClasses().size() == 1;
+ assert container.getBeanManager().getEnabledDecoratorClasses().iterator().next() ==
Dec.class;
+ container.stopContainer();
+ }
+
+ @Test
+ public void testBeansXmlDoesntExist()
+ {
+ testWithBeansXmlAndExpectException("nope.xml", new
WeldXmlException(XmlMessage.LOAD_ERROR));
+ }
+
+ @Test(groups="stub")
+ public void testCannotGetDocumentBuilder()
+ {
+ }
+
+ @Test
+ public void testCannotLoadFile() throws MalformedURLException
+ {
+ List<Class<?>> beans = Collections.emptyList();
+ new FailedDeployment(beans, Arrays.asList(new
URL("http://foo.bar/beans.xml"))).runAndExpect(new
WeldXmlException(XmlMessage.LOAD_ERROR));
+ }
+
+ @Test
+ public void testParsingError()
+ {
+ testWithBeansXmlAndExpectException("unparseable.xml", new
WeldXmlException(XmlMessage.PARSING_ERROR));
+ }
+
+ @Test
+ public void testCannotLoadClass()
+ {
+ testWithBeansXmlAndExpectException("unloadable.xml", new
WeldXmlException(XmlMessage.CANNOT_LOAD_CLASS));
+ }
+
+}
Added: core/trunk/tests/src/test/java/org/jboss/weld/tests/unit/bootstrap/xml/Dec.java
===================================================================
--- core/trunk/tests/src/test/java/org/jboss/weld/tests/unit/bootstrap/xml/Dec.java
(rev 0)
+++
core/trunk/tests/src/test/java/org/jboss/weld/tests/unit/bootstrap/xml/Dec.java 2009-12-10
11:44:51 UTC (rev 5265)
@@ -0,0 +1,11 @@
+package org.jboss.weld.tests.unit.bootstrap.xml;
+
+import javax.decorator.Decorator;
+import javax.decorator.Delegate;
+import javax.inject.Inject;
+
+@Decorator
+public class Dec
+{
+ @Inject @Delegate Plain plain;
+}
Added: core/trunk/tests/src/test/java/org/jboss/weld/tests/unit/bootstrap/xml/Int.java
===================================================================
--- core/trunk/tests/src/test/java/org/jboss/weld/tests/unit/bootstrap/xml/Int.java
(rev 0)
+++
core/trunk/tests/src/test/java/org/jboss/weld/tests/unit/bootstrap/xml/Int.java 2009-12-10
11:44:51 UTC (rev 5265)
@@ -0,0 +1,10 @@
+package org.jboss.weld.tests.unit.bootstrap.xml;
+
+import javax.interceptor.Interceptor;
+
+@Interceptor
+@IntBind
+public class Int
+{
+
+}
Added:
core/trunk/tests/src/test/java/org/jboss/weld/tests/unit/bootstrap/xml/IntBind.java
===================================================================
--- core/trunk/tests/src/test/java/org/jboss/weld/tests/unit/bootstrap/xml/IntBind.java
(rev 0)
+++
core/trunk/tests/src/test/java/org/jboss/weld/tests/unit/bootstrap/xml/IntBind.java 2009-12-10
11:44:51 UTC (rev 5265)
@@ -0,0 +1,16 @@
+package org.jboss.weld.tests.unit.bootstrap.xml;
+
+import java.lang.annotation.Inherited;
+import java.lang.annotation.Retention;
+import java.lang.annotation.Target;
+import static java.lang.annotation.ElementType.*;
+import static java.lang.annotation.RetentionPolicy.*;
+import javax.interceptor.InterceptorBinding;
+
+@InterceptorBinding
+@Inherited
+@Target( { TYPE, METHOD })
+@Retention(RUNTIME)
+public @interface IntBind
+{
+}
\ No newline at end of file
Added: core/trunk/tests/src/test/java/org/jboss/weld/tests/unit/bootstrap/xml/Plain.java
===================================================================
--- core/trunk/tests/src/test/java/org/jboss/weld/tests/unit/bootstrap/xml/Plain.java
(rev 0)
+++
core/trunk/tests/src/test/java/org/jboss/weld/tests/unit/bootstrap/xml/Plain.java 2009-12-10
11:44:51 UTC (rev 5265)
@@ -0,0 +1,6 @@
+package org.jboss.weld.tests.unit.bootstrap.xml;
+
+public class Plain
+{
+
+}
Added:
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/alternative.xml
===================================================================
---
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/alternative.xml
(rev 0)
+++
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/alternative.xml 2009-12-10
11:44:51 UTC (rev 5265)
@@ -0,0 +1,5 @@
+<beans>
+ <alternatives>
+ <class>org.jboss.weld.tests.unit.bootstrap.xml.Alt</class>
+ </alternatives>
+</beans>
\ No newline at end of file
Added:
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/decorator.xml
===================================================================
---
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/decorator.xml
(rev 0)
+++
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/decorator.xml 2009-12-10
11:44:51 UTC (rev 5265)
@@ -0,0 +1,5 @@
+<beans>
+ <decorators>
+ <class>org.jboss.weld.tests.unit.bootstrap.xml.Dec</class>
+ </decorators>
+</beans>
\ No newline at end of file
Added:
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/interceptor.xml
===================================================================
---
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/interceptor.xml
(rev 0)
+++
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/interceptor.xml 2009-12-10
11:44:51 UTC (rev 5265)
@@ -0,0 +1,5 @@
+<beans>
+ <interceptors>
+ <class>org.jboss.weld.tests.unit.bootstrap.xml.Int</class>
+ </interceptors>
+</beans>
\ No newline at end of file
Added:
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/multipleAlternativeBlocks.xml
===================================================================
---
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/multipleAlternativeBlocks.xml
(rev 0)
+++
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/multipleAlternativeBlocks.xml 2009-12-10
11:44:51 UTC (rev 5265)
@@ -0,0 +1,8 @@
+<beans>
+ <alternatives>
+ <class>org.jboss.weld.tests.unit.bootstrap.Foo</class>
+ </alternatives>
+ <alternatives>
+ <class>org.jboss.weld.tests.unit.bootstrap.Bar</class>
+ </alternatives>
+</beans>
\ No newline at end of file
Added:
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/multipleDecoratorBlocks.xml
===================================================================
---
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/multipleDecoratorBlocks.xml
(rev 0)
+++
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/multipleDecoratorBlocks.xml 2009-12-10
11:44:51 UTC (rev 5265)
@@ -0,0 +1,8 @@
+<beans>
+ <decorators>
+ <class>org.jboss.weld.tests.unit.bootstrap.Foo</class>
+ </decorators>
+ <decorators>
+ <class>org.jboss.weld.tests.unit.bootstrap.Bar</class>
+ </decorators>
+</beans>
\ No newline at end of file
Added:
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/multipleInterceptorsBlocks.xml
===================================================================
---
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/multipleInterceptorsBlocks.xml
(rev 0)
+++
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/multipleInterceptorsBlocks.xml 2009-12-10
11:44:51 UTC (rev 5265)
@@ -0,0 +1,8 @@
+<beans>
+ <interceptors>
+ <class>org.jboss.weld.tests.unit.bootstrap.Foo</class>
+ </interceptors>
+ <interceptors>
+ <class>org.jboss.weld.tests.unit.bootstrap.Bar</class>
+ </interceptors>
+</beans>
\ No newline at end of file
Added:
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/unloadable.xml
===================================================================
---
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/unloadable.xml
(rev 0)
+++
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/unloadable.xml 2009-12-10
11:44:51 UTC (rev 5265)
@@ -0,0 +1,5 @@
+<beans>
+ <alternatives>
+ <class>foo.Bar</class>
+ </alternatives>
+</beans>
\ No newline at end of file
Added:
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/unparseable.xml
===================================================================
---
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/unparseable.xml
(rev 0)
+++
core/trunk/tests/src/test/resources/org/jboss/weld/tests/unit/bootstrap/xml/unparseable.xml 2009-12-10
11:44:51 UTC (rev 5265)
@@ -0,0 +1,5 @@
+<beans>
+ <alternatives
+ <class>foo.Bar</class>
+ </alternatives>
+</beans>
\ No newline at end of file