Author: pete.muir(a)jboss.org
Date: 2010-06-13 08:55:56 -0400 (Sun, 13 Jun 2010)
New Revision: 6425
Added:
core/trunk/tests-arquillian/src/test/java/org/jboss/weld/tests/alternatives/TestAlternative.java
Removed:
core/trunk/tests-arquillian/src/test/java/org/jboss/weld/tests/alternatives/Test.java
Modified:
core/trunk/tests-arquillian/src/test/java/org/jboss/weld/tests/alternatives/Alternatives2Test.java
core/trunk/tests-arquillian/src/test/java/org/jboss/weld/tests/alternatives/AlternativesTest.java
core/trunk/tests-arquillian/src/test/java/org/jboss/weld/tests/alternatives/Producer.java
Log:
remove name conflicts
Modified:
core/trunk/tests-arquillian/src/test/java/org/jboss/weld/tests/alternatives/Alternatives2Test.java
===================================================================
---
core/trunk/tests-arquillian/src/test/java/org/jboss/weld/tests/alternatives/Alternatives2Test.java 2010-06-12
19:25:25 UTC (rev 6424)
+++
core/trunk/tests-arquillian/src/test/java/org/jboss/weld/tests/alternatives/Alternatives2Test.java 2010-06-13
12:55:56 UTC (rev 6425)
@@ -24,6 +24,7 @@
import org.jboss.shrinkwrap.api.ShrinkWrap;
import org.jboss.shrinkwrap.api.spec.JavaArchive;
import org.junit.Assert;
+import org.junit.Test;
import org.junit.runner.RunWith;
@RunWith(Arquillian.class)
@@ -37,7 +38,7 @@
.as(JavaArchive.class);
}
- @org.junit.Test
+ @Test
public void testAlternativesOnProducers(Consumer consumer)
{
Assert.assertEquals("Normal", consumer.getFoo().getName());
Modified:
core/trunk/tests-arquillian/src/test/java/org/jboss/weld/tests/alternatives/AlternativesTest.java
===================================================================
---
core/trunk/tests-arquillian/src/test/java/org/jboss/weld/tests/alternatives/AlternativesTest.java 2010-06-12
19:25:25 UTC (rev 6424)
+++
core/trunk/tests-arquillian/src/test/java/org/jboss/weld/tests/alternatives/AlternativesTest.java 2010-06-13
12:55:56 UTC (rev 6425)
@@ -22,6 +22,7 @@
import org.jboss.shrinkwrap.api.BeanArchive;
import org.jboss.shrinkwrap.api.ShrinkWrap;
import org.junit.Assert;
+import org.junit.Test;
import org.junit.runner.RunWith;
@RunWith(Arquillian.class)
@@ -31,11 +32,11 @@
public static Archive<?> deploy()
{
return ShrinkWrap.create("test.jar", BeanArchive.class)
- .stereotype(Test.class)
+ .stereotype(TestAlternative.class)
.addPackage(Alternatives2Test.class.getPackage());
}
- @org.junit.Test
+ @Test
public void testAlternativesOnProducers(Consumer consumer)
{
Assert.assertEquals("Test", consumer.getFoo().getName());
Modified:
core/trunk/tests-arquillian/src/test/java/org/jboss/weld/tests/alternatives/Producer.java
===================================================================
---
core/trunk/tests-arquillian/src/test/java/org/jboss/weld/tests/alternatives/Producer.java 2010-06-12
19:25:25 UTC (rev 6424)
+++
core/trunk/tests-arquillian/src/test/java/org/jboss/weld/tests/alternatives/Producer.java 2010-06-13
12:55:56 UTC (rev 6425)
@@ -21,7 +21,7 @@
public class Producer
{
- @Produces @Test
+ @Produces @TestAlternative
public Foo getFoo()
{
return new Foo("Test");
Deleted:
core/trunk/tests-arquillian/src/test/java/org/jboss/weld/tests/alternatives/Test.java
===================================================================
---
core/trunk/tests-arquillian/src/test/java/org/jboss/weld/tests/alternatives/Test.java 2010-06-12
19:25:25 UTC (rev 6424)
+++
core/trunk/tests-arquillian/src/test/java/org/jboss/weld/tests/alternatives/Test.java 2010-06-13
12:55:56 UTC (rev 6425)
@@ -1,31 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2010, Red Hat, Inc., and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
http://www.apache.org/licenses/LICENSE-2.0
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.jboss.weld.tests.alternatives;
-
-import java.lang.annotation.ElementType;
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-import java.lang.annotation.Target;
-
-import javax.enterprise.inject.Alternative;
-import javax.enterprise.inject.Stereotype;
-
-@Stereotype
-@Alternative
-(a)Retention(RetentionPolicy.RUNTIME)
-(a)Target({ElementType.TYPE, ElementType.METHOD, ElementType.FIELD})
-public @interface Test {}
\ No newline at end of file
Copied:
core/trunk/tests-arquillian/src/test/java/org/jboss/weld/tests/alternatives/TestAlternative.java
(from rev 6424,
core/trunk/tests-arquillian/src/test/java/org/jboss/weld/tests/alternatives/Test.java)
===================================================================
---
core/trunk/tests-arquillian/src/test/java/org/jboss/weld/tests/alternatives/TestAlternative.java
(rev 0)
+++
core/trunk/tests-arquillian/src/test/java/org/jboss/weld/tests/alternatives/TestAlternative.java 2010-06-13
12:55:56 UTC (rev 6425)
@@ -0,0 +1,31 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2010, Red Hat, Inc., and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.weld.tests.alternatives;
+
+import java.lang.annotation.ElementType;
+import java.lang.annotation.Retention;
+import java.lang.annotation.RetentionPolicy;
+import java.lang.annotation.Target;
+
+import javax.enterprise.inject.Alternative;
+import javax.enterprise.inject.Stereotype;
+
+@Stereotype
+@Alternative
+(a)Retention(RetentionPolicy.RUNTIME)
+(a)Target({ElementType.TYPE, ElementType.METHOD, ElementType.FIELD})
+public @interface TestAlternative {}
\ No newline at end of file