[jboss-svn-commits] JBoss Common SVN: r3805 - in arquillian/trunk/demo/src/test/java/com/acme: resource and 1 other directories.
jboss-svn-commits at lists.jboss.org
jboss-svn-commits at lists.jboss.org
Fri Nov 27 07:06:03 EST 2009
Author: aslak
Date: 2009-11-27 07:06:03 -0500 (Fri, 27 Nov 2009)
New Revision: 3805
Added:
arquillian/trunk/demo/src/test/java/com/acme/ejb/InjectionTestCase.java
arquillian/trunk/demo/src/test/java/com/acme/resource/InjectionTestCase.java
arquillian/trunk/demo/src/test/java/com/acme/weld/InjectionTestCase.java
Removed:
arquillian/trunk/demo/src/test/java/com/acme/ejb/GreetingManagerTest.java
arquillian/trunk/demo/src/test/java/com/acme/resource/ResourcesTest.java
arquillian/trunk/demo/src/test/java/com/acme/weld/WeldGreetingsTest.java
Log:
ARQ-17 Renamed test cases
Deleted: arquillian/trunk/demo/src/test/java/com/acme/ejb/GreetingManagerTest.java
===================================================================
--- arquillian/trunk/demo/src/test/java/com/acme/ejb/GreetingManagerTest.java 2009-11-27 12:04:27 UTC (rev 3804)
+++ arquillian/trunk/demo/src/test/java/com/acme/ejb/GreetingManagerTest.java 2009-11-27 12:06:03 UTC (rev 3805)
@@ -1,59 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2009, Red Hat Middleware LLC, 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 com.acme.ejb;
-
-import javax.ejb.EJB;
-
-
-import org.jboss.arquillian.api.Deployment;
-import org.jboss.arquillian.junit.Arquillian;
-import org.jboss.shrinkwrap.api.Archives;
-import org.jboss.shrinkwrap.api.spec.JavaArchive;
-import org.junit.Assert;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-
-/**
- * GreetingManagerTest
- *
- * @author <a href="mailto:aslak at conduct.no">Aslak Knutsen</a>
- * @version $Revision: $
- */
- at RunWith(Arquillian.class)
-public class GreetingManagerTest
-{
- @Deployment
- public static JavaArchive createDeployment() {
- return Archives.create("test.jar", JavaArchive.class)
- .addClasses(
- GreetingManager.class,
- GreetingManagerBean.class);
- }
-
- @EJB
- private GreetingManager greetingManager;
-
- @Test
- public void shouldGreetUser() throws Exception {
-
- String userName = "Devoxx";
-
- Assert.assertEquals(
- "Hello " + userName,
- greetingManager.greet(userName));
- }
-}
Copied: arquillian/trunk/demo/src/test/java/com/acme/ejb/InjectionTestCase.java (from rev 3790, arquillian/trunk/demo/src/test/java/com/acme/ejb/GreetingManagerTest.java)
===================================================================
--- arquillian/trunk/demo/src/test/java/com/acme/ejb/InjectionTestCase.java (rev 0)
+++ arquillian/trunk/demo/src/test/java/com/acme/ejb/InjectionTestCase.java 2009-11-27 12:06:03 UTC (rev 3805)
@@ -0,0 +1,59 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2009, Red Hat Middleware LLC, 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 com.acme.ejb;
+
+import javax.ejb.EJB;
+
+
+import org.jboss.arquillian.api.Deployment;
+import org.jboss.arquillian.junit.Arquillian;
+import org.jboss.shrinkwrap.api.Archives;
+import org.jboss.shrinkwrap.api.spec.JavaArchive;
+import org.junit.Assert;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+
+/**
+ * GreetingManagerTest
+ *
+ * @author <a href="mailto:aslak at conduct.no">Aslak Knutsen</a>
+ * @version $Revision: $
+ */
+ at RunWith(Arquillian.class)
+public class InjectionTestCase
+{
+ @Deployment
+ public static JavaArchive createDeployment() {
+ return Archives.create("test.jar", JavaArchive.class)
+ .addClasses(
+ GreetingManager.class,
+ GreetingManagerBean.class);
+ }
+
+ @EJB
+ private GreetingManager greetingManager;
+
+ @Test
+ public void shouldGreetUser() throws Exception {
+
+ String userName = "Devoxx";
+
+ Assert.assertEquals(
+ "Hello " + userName,
+ greetingManager.greet(userName));
+ }
+}
Copied: arquillian/trunk/demo/src/test/java/com/acme/resource/InjectionTestCase.java (from rev 3804, arquillian/trunk/demo/src/test/java/com/acme/resource/ResourcesTest.java)
===================================================================
--- arquillian/trunk/demo/src/test/java/com/acme/resource/InjectionTestCase.java (rev 0)
+++ arquillian/trunk/demo/src/test/java/com/acme/resource/InjectionTestCase.java 2009-11-27 12:06:03 UTC (rev 3805)
@@ -0,0 +1,51 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2009, Red Hat Middleware LLC, 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 com.acme.resource;
+
+import javax.annotation.Resource;
+import javax.mail.Session;
+
+import org.jboss.arquillian.api.Deployment;
+import org.jboss.arquillian.junit.Arquillian;
+import org.jboss.shrinkwrap.api.Archives;
+import org.jboss.shrinkwrap.api.spec.JavaArchive;
+import org.junit.Assert;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+
+/**
+ * ResourcesTest
+ *
+ * @author <a href="mailto:aslak at conduct.no">Aslak Knutsen</a>
+ * @version $Revision: $
+ */
+ at RunWith(Arquillian.class)
+public class InjectionTestCase
+{
+ @Deployment
+ public static JavaArchive createDeployment() {
+ return Archives.create("test.jar", JavaArchive.class);
+ }
+
+ @Resource(mappedName = "java:/Mail") Session mailSession;
+
+ @Test
+ public void shouldBeAbleToGreet() throws Exception {
+
+ Assert.assertNotNull(mailSession);
+ }
+}
Deleted: arquillian/trunk/demo/src/test/java/com/acme/resource/ResourcesTest.java
===================================================================
--- arquillian/trunk/demo/src/test/java/com/acme/resource/ResourcesTest.java 2009-11-27 12:04:27 UTC (rev 3804)
+++ arquillian/trunk/demo/src/test/java/com/acme/resource/ResourcesTest.java 2009-11-27 12:06:03 UTC (rev 3805)
@@ -1,51 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2009, Red Hat Middleware LLC, 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 com.acme.resource;
-
-import javax.annotation.Resource;
-import javax.mail.Session;
-
-import org.jboss.arquillian.api.Deployment;
-import org.jboss.arquillian.junit.Arquillian;
-import org.jboss.shrinkwrap.api.Archives;
-import org.jboss.shrinkwrap.api.spec.JavaArchive;
-import org.junit.Assert;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-
-/**
- * ResourcesTest
- *
- * @author <a href="mailto:aslak at conduct.no">Aslak Knutsen</a>
- * @version $Revision: $
- */
- at RunWith(Arquillian.class)
-public class ResourcesTest
-{
- @Deployment
- public static JavaArchive createDeployment() {
- return Archives.create("test.jar", JavaArchive.class);
- }
-
- @Resource(mappedName = "java:/Mail") Session mailSession;
-
- @Test
- public void shouldBeAbleToGreet() throws Exception {
-
- Assert.assertNotNull(mailSession);
- }
-}
Copied: arquillian/trunk/demo/src/test/java/com/acme/weld/InjectionTestCase.java (from rev 3804, arquillian/trunk/demo/src/test/java/com/acme/weld/WeldGreetingsTest.java)
===================================================================
--- arquillian/trunk/demo/src/test/java/com/acme/weld/InjectionTestCase.java (rev 0)
+++ arquillian/trunk/demo/src/test/java/com/acme/weld/InjectionTestCase.java 2009-11-27 12:06:03 UTC (rev 3805)
@@ -0,0 +1,65 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2009, Red Hat Middleware LLC, 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 com.acme.weld;
+
+import javax.inject.Inject;
+
+import org.jboss.arquillian.api.Deployment;
+import org.jboss.arquillian.junit.Arquillian;
+import org.jboss.shrinkwrap.api.Archives;
+import org.jboss.shrinkwrap.api.Paths;
+import org.jboss.shrinkwrap.api.spec.JavaArchive;
+import org.jboss.shrinkwrap.impl.base.asset.ByteArrayAsset;
+import org.junit.Assert;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+
+import com.acme.ejb.GreetingManager;
+import com.acme.ejb.GreetingManagerBean;
+
+/**
+ * WeldGreetingsTest
+ *
+ * @author <a href="mailto:aslak at conduct.no">Aslak Knutsen</a>
+ * @version $Revision: $
+ */
+ at RunWith(Arquillian.class)
+public class InjectionTestCase
+{
+ @Deployment
+ public static JavaArchive createDeployment() {
+ return Archives.create("test.jar", JavaArchive.class)
+ .addClasses(
+ GreetingManager.class,
+ GreetingManagerBean.class)
+ .addManifestResource(
+ new ByteArrayAsset("<beans/>".getBytes()),
+ Paths.create("beans.xml"));
+ }
+
+ @Inject GreetingManager greetingManager;
+
+ @Test
+ public void shouldBeAbleToGreet() throws Exception {
+
+ String userName = "Devoxx";
+
+ Assert.assertEquals(
+ "Hello " + userName,
+ greetingManager.greet(userName));
+ }
+}
Deleted: arquillian/trunk/demo/src/test/java/com/acme/weld/WeldGreetingsTest.java
===================================================================
--- arquillian/trunk/demo/src/test/java/com/acme/weld/WeldGreetingsTest.java 2009-11-27 12:04:27 UTC (rev 3804)
+++ arquillian/trunk/demo/src/test/java/com/acme/weld/WeldGreetingsTest.java 2009-11-27 12:06:03 UTC (rev 3805)
@@ -1,65 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2009, Red Hat Middleware LLC, 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 com.acme.weld;
-
-import javax.inject.Inject;
-
-import org.jboss.arquillian.api.Deployment;
-import org.jboss.arquillian.junit.Arquillian;
-import org.jboss.shrinkwrap.api.Archives;
-import org.jboss.shrinkwrap.api.Paths;
-import org.jboss.shrinkwrap.api.spec.JavaArchive;
-import org.jboss.shrinkwrap.impl.base.asset.ByteArrayAsset;
-import org.junit.Assert;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-
-import com.acme.ejb.GreetingManager;
-import com.acme.ejb.GreetingManagerBean;
-
-/**
- * WeldGreetingsTest
- *
- * @author <a href="mailto:aslak at conduct.no">Aslak Knutsen</a>
- * @version $Revision: $
- */
- at RunWith(Arquillian.class)
-public class WeldGreetingsTest
-{
- @Deployment
- public static JavaArchive createDeployment() {
- return Archives.create("test.jar", JavaArchive.class)
- .addClasses(
- GreetingManager.class,
- GreetingManagerBean.class)
- .addManifestResource(
- new ByteArrayAsset("<beans/>".getBytes()),
- Paths.create("beans.xml"));
- }
-
- @Inject GreetingManager greetingManager;
-
- @Test
- public void shouldBeAbleToGreet() throws Exception {
-
- String userName = "Devoxx";
-
- Assert.assertEquals(
- "Hello " + userName,
- greetingManager.greet(userName));
- }
-}
More information about the jboss-svn-commits
mailing list