You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@deltaspike.apache.org by gp...@apache.org on 2014/12/20 17:46:11 UTC

deltaspike git commit: DELTASPIKE-803 exclude ee7 tests for ee6 servers

Repository: deltaspike
Updated Branches:
  refs/heads/master 44c27f1f9 -> 27b756e04


DELTASPIKE-803 exclude ee7 tests for ee6 servers

 (and fixed typo)


Project: http://git-wip-us.apache.org/repos/asf/deltaspike/repo
Commit: http://git-wip-us.apache.org/repos/asf/deltaspike/commit/27b756e0
Tree: http://git-wip-us.apache.org/repos/asf/deltaspike/tree/27b756e0
Diff: http://git-wip-us.apache.org/repos/asf/deltaspike/diff/27b756e0

Branch: refs/heads/master
Commit: 27b756e04827607a58b87fe580acf6a6034836a7
Parents: 44c27f1
Author: gpetracek <gp...@apache.org>
Authored: Sat Dec 20 17:43:52 2014 +0100
Committer: gpetracek <gp...@apache.org>
Committed: Sat Dec 20 17:44:50 2014 +0100

----------------------------------------------------------------------
 ...ewAccessScopedWithFViewActionWebAppTest.java | 92 ++++++++++++++++++++
 ...ewAccessScopedWithFViewActionWebAppTest.java | 92 --------------------
 deltaspike/parent/code/pom.xml                  | 10 +++
 .../test/category/WebEE7ProfileCategory.java    | 27 ++++++
 4 files changed, 129 insertions(+), 92 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/deltaspike/blob/27b756e0/deltaspike/modules/jsf/impl/src/test/java/org/apache/deltaspike/test/jsf/impl/scope/viewaccess/ViewAccessScopedWithFViewActionWebAppTest.java
----------------------------------------------------------------------
diff --git a/deltaspike/modules/jsf/impl/src/test/java/org/apache/deltaspike/test/jsf/impl/scope/viewaccess/ViewAccessScopedWithFViewActionWebAppTest.java b/deltaspike/modules/jsf/impl/src/test/java/org/apache/deltaspike/test/jsf/impl/scope/viewaccess/ViewAccessScopedWithFViewActionWebAppTest.java
new file mode 100644
index 0000000..5439893
--- /dev/null
+++ b/deltaspike/modules/jsf/impl/src/test/java/org/apache/deltaspike/test/jsf/impl/scope/viewaccess/ViewAccessScopedWithFViewActionWebAppTest.java
@@ -0,0 +1,92 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you 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.apache.deltaspike.test.jsf.impl.scope.viewaccess;
+
+import org.apache.deltaspike.test.category.WebEE7ProfileCategory;
+import org.apache.deltaspike.test.jsf.impl.scope.viewaccess.beans.ViewAccessScopedBeanX;
+import org.apache.deltaspike.test.jsf.impl.scope.viewaccess.beans.ViewAccessScopedBeanY;
+import org.apache.deltaspike.test.jsf.impl.util.ArchiveUtils;
+import org.jboss.arquillian.container.test.api.Deployment;
+import org.jboss.arquillian.container.test.api.RunAsClient;
+import org.jboss.arquillian.drone.api.annotation.Drone;
+import org.jboss.arquillian.junit.Arquillian;
+import org.jboss.arquillian.test.api.ArquillianResource;
+import org.jboss.arquillian.warp.WarpTest;
+import org.jboss.shrinkwrap.api.ShrinkWrap;
+import org.jboss.shrinkwrap.api.asset.EmptyAsset;
+import org.jboss.shrinkwrap.api.spec.WebArchive;
+import org.junit.Assert;
+import org.junit.Test;
+import org.junit.experimental.categories.Category;
+import org.junit.runner.RunWith;
+import org.openqa.selenium.By;
+import org.openqa.selenium.WebDriver;
+import org.openqa.selenium.WebElement;
+import org.openqa.selenium.support.ui.ExpectedConditions;
+
+import java.net.URL;
+
+@WarpTest
+@RunWith(Arquillian.class)
+@Category(WebEE7ProfileCategory.class)
+public class ViewAccessScopedWithFViewActionWebAppTest
+{
+    @Drone
+    private WebDriver driver;
+
+    @ArquillianResource
+    private URL contextPath;
+
+    @Deployment
+    public static WebArchive deploy()
+    {
+        String simpleName = ViewAccessScopedWithFViewActionWebAppTest.class.getSimpleName();
+        String archiveName = simpleName.substring(0, 1).toLowerCase() + simpleName.substring(1);
+
+        return ShrinkWrap
+                .create(WebArchive.class, archiveName + ".war")
+                .addClass(ViewAccessScopedBeanX.class)
+                .addClass(ViewAccessScopedBeanY.class)
+                .addAsLibraries(ArchiveUtils.getDeltaSpikeCoreAndJsfArchive())
+                .addAsLibraries(ArchiveUtils.getDeltaSpikeSecurityArchive())
+                .addAsWebInfResource("default/WEB-INF/web.xml", "web.xml")
+                .addAsWebResource("viewAccessScopedContextTest/index.xhtml", "index.xhtml")
+                .addAsWebResource("viewAccessScopedContextTest/next.xhtml", "next.xhtml")
+                .addAsWebInfResource(EmptyAsset.INSTANCE, "beans.xml");
+    }
+
+    @Test
+    @RunAsClient
+    public void testForward() throws Exception
+    {
+        driver.get(new URL(contextPath, "index.xhtml").toString());
+
+        WebElement inputFieldX = driver.findElement(By.id("form:firstValue"));
+        inputFieldX.sendKeys("abc");
+        WebElement inputFieldY = driver.findElement(By.id("form:secondValue"));
+        inputFieldY.sendKeys("xyz");
+
+        WebElement button = driver.findElement(By.id("form:next"));
+        button.click();
+
+        Assert.assertTrue(ExpectedConditions.textToBePresentInElement(By.id("firstValue"), "abc").apply(driver));
+        Assert.assertTrue(ExpectedConditions.textToBePresentInElement(By.id("secondValue"), "xyz").apply(driver));
+
+    }
+}

http://git-wip-us.apache.org/repos/asf/deltaspike/blob/27b756e0/deltaspike/modules/jsf/impl/src/test/java/org/apache/deltaspike/test/jsf/impl/scope/viewaccess/iewAccessScopedWithFViewActionWebAppTest.java
----------------------------------------------------------------------
diff --git a/deltaspike/modules/jsf/impl/src/test/java/org/apache/deltaspike/test/jsf/impl/scope/viewaccess/iewAccessScopedWithFViewActionWebAppTest.java b/deltaspike/modules/jsf/impl/src/test/java/org/apache/deltaspike/test/jsf/impl/scope/viewaccess/iewAccessScopedWithFViewActionWebAppTest.java
deleted file mode 100644
index 83ff901..0000000
--- a/deltaspike/modules/jsf/impl/src/test/java/org/apache/deltaspike/test/jsf/impl/scope/viewaccess/iewAccessScopedWithFViewActionWebAppTest.java
+++ /dev/null
@@ -1,92 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you 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.apache.deltaspike.test.jsf.impl.scope.viewaccess;
-
-import org.apache.deltaspike.test.category.WebProfileCategory;
-import org.apache.deltaspike.test.jsf.impl.scope.viewaccess.beans.ViewAccessScopedBeanX;
-import org.apache.deltaspike.test.jsf.impl.scope.viewaccess.beans.ViewAccessScopedBeanY;
-import org.apache.deltaspike.test.jsf.impl.util.ArchiveUtils;
-import org.jboss.arquillian.container.test.api.Deployment;
-import org.jboss.arquillian.container.test.api.RunAsClient;
-import org.jboss.arquillian.drone.api.annotation.Drone;
-import org.jboss.arquillian.junit.Arquillian;
-import org.jboss.arquillian.test.api.ArquillianResource;
-import org.jboss.arquillian.warp.WarpTest;
-import org.jboss.shrinkwrap.api.ShrinkWrap;
-import org.jboss.shrinkwrap.api.asset.EmptyAsset;
-import org.jboss.shrinkwrap.api.spec.WebArchive;
-import org.junit.Assert;
-import org.junit.Test;
-import org.junit.experimental.categories.Category;
-import org.junit.runner.RunWith;
-import org.openqa.selenium.By;
-import org.openqa.selenium.WebDriver;
-import org.openqa.selenium.WebElement;
-import org.openqa.selenium.support.ui.ExpectedConditions;
-
-import java.net.URL;
-
-@WarpTest
-@RunWith(Arquillian.class)
-@Category(WebProfileCategory.class)
-public class iewAccessScopedWithFViewActionWebAppTest
-{
-    @Drone
-    private WebDriver driver;
-
-    @ArquillianResource
-    private URL contextPath;
-
-    @Deployment
-    public static WebArchive deploy()
-    {
-        String simpleName = iewAccessScopedWithFViewActionWebAppTest.class.getSimpleName();
-        String archiveName = simpleName.substring(0, 1).toLowerCase() + simpleName.substring(1);
-
-        return ShrinkWrap
-                .create(WebArchive.class, archiveName + ".war")
-                .addClass(ViewAccessScopedBeanX.class)
-                .addClass(ViewAccessScopedBeanY.class)
-                .addAsLibraries(ArchiveUtils.getDeltaSpikeCoreAndJsfArchive())
-                .addAsLibraries(ArchiveUtils.getDeltaSpikeSecurityArchive())
-                .addAsWebInfResource("default/WEB-INF/web.xml", "web.xml")
-                .addAsWebResource("viewAccessScopedContextTest/index.xhtml", "index.xhtml")
-                .addAsWebResource("viewAccessScopedContextTest/next.xhtml", "next.xhtml")
-                .addAsWebInfResource(EmptyAsset.INSTANCE, "beans.xml");
-    }
-
-    @Test
-    @RunAsClient
-    public void testForward() throws Exception
-    {
-        driver.get(new URL(contextPath, "index.xhtml").toString());
-
-        WebElement inputFieldX = driver.findElement(By.id("form:firstValue"));
-        inputFieldX.sendKeys("abc");
-        WebElement inputFieldY = driver.findElement(By.id("form:secondValue"));
-        inputFieldY.sendKeys("xyz");
-
-        WebElement button = driver.findElement(By.id("form:next"));
-        button.click();
-
-        Assert.assertTrue(ExpectedConditions.textToBePresentInElement(By.id("firstValue"), "abc").apply(driver));
-        Assert.assertTrue(ExpectedConditions.textToBePresentInElement(By.id("secondValue"), "xyz").apply(driver));
-
-    }
-}

http://git-wip-us.apache.org/repos/asf/deltaspike/blob/27b756e0/deltaspike/parent/code/pom.xml
----------------------------------------------------------------------
diff --git a/deltaspike/parent/code/pom.xml b/deltaspike/parent/code/pom.xml
index b3515b2..61a6939 100644
--- a/deltaspike/parent/code/pom.xml
+++ b/deltaspike/parent/code/pom.xml
@@ -163,6 +163,7 @@
                             <!-- Ignore these groups because they don't work with embedded OWB -->
                             <excludedGroups>
                                 org.apache.deltaspike.test.category.WebProfileCategory,
+                                org.apache.deltaspike.test.category.WebEE7ProfileCategory,
                                 org.apache.deltaspike.test.category.FullProfileCategory,
                                 org.apache.deltaspike.test.category.EnterpriseArchiveProfileCategory
                             </excludedGroups>
@@ -234,6 +235,7 @@
                             <!-- Ignore these groups because they don't work with embedded OWB -->
                             <excludedGroups>
                                 org.apache.deltaspike.test.category.WebProfileCategory,
+                                org.apache.deltaspike.test.category.WebEE7ProfileCategory,
                                 org.apache.deltaspike.test.category.FullProfileCategory,
                                 org.apache.deltaspike.test.category.EnterpriseArchiveProfileCategory
                             </excludedGroups>
@@ -321,6 +323,7 @@
                             <!-- Ignore these groups because they don't work with embedded Weld -->
                             <excludedGroups>
                                 org.apache.deltaspike.test.category.WebProfileCategory,
+                                org.apache.deltaspike.test.category.WebEE7ProfileCategory,
                                 org.apache.deltaspike.test.category.FullProfileCategory,
                                 org.apache.deltaspike.test.category.EnterpriseArchiveProfileCategory
                             </excludedGroups>
@@ -489,6 +492,7 @@
                             there are currently issues with arquillian. if a test isn't restricted to an environment,
                             no category is used for the test-class. -->
                             <excludedGroups>
+                                org.apache.deltaspike.test.category.WebEE7ProfileCategory,
                                 org.apache.deltaspike.test.category.SeCategory
                             </excludedGroups>
                         </configuration>
@@ -568,6 +572,7 @@
                             no category is used for the test-class. -->
                             <excludedGroups>
                                 org.apache.deltaspike.test.category.FullProfileCategory,
+                                org.apache.deltaspike.test.category.WebEE7ProfileCategory,
                                 org.apache.deltaspike.test.category.SeCategory
                             </excludedGroups>
                         </configuration>
@@ -641,6 +646,7 @@
                             no category is used for the test-class. -->
                             <excludedGroups>
                                 org.apache.deltaspike.test.category.FullProfileCategory,
+                                org.apache.deltaspike.test.category.WebEE7ProfileCategory,
                                 org.apache.deltaspike.test.category.SeCategory
                             </excludedGroups>
                         </configuration>
@@ -731,6 +737,7 @@
                             no category is used for the test-class. -->
                             <excludedGroups>
                                 org.apache.deltaspike.test.category.FullProfileCategory,
+                                org.apache.deltaspike.test.category.WebEE7ProfileCategory,
                                 org.apache.deltaspike.test.category.SeCategory
                             </excludedGroups>
                         </configuration>
@@ -1027,6 +1034,7 @@
                             there are currently issues with arquillian. if a test isn't restricted to an environment,
                             no category is used for the test-class. -->
                             <excludedGroups>
+                                org.apache.deltaspike.test.category.WebEE7ProfileCategory,
                                 org.apache.deltaspike.test.category.SeCategory
                             </excludedGroups>
                         </configuration>
@@ -1082,6 +1090,7 @@
                      no category is used for the test-class. -->
                             <excludedGroups>
                                 org.apache.deltaspike.test.category.FullProfileCategory,
+                                org.apache.deltaspike.test.category.WebEE7ProfileCategory,
                                 org.apache.deltaspike.test.category.SeCategory
                             </excludedGroups>
                         </configuration>
@@ -1144,6 +1153,7 @@
                             there are currently issues with arquillian. if a test isn't restricted to an environment,
                             no category is used for the test-class. -->
                             <excludedGroups>
+                                org.apache.deltaspike.test.category.WebEE7ProfileCategory,
                                 org.apache.deltaspike.test.category.SeCategory
                             </excludedGroups>
                         </configuration>

http://git-wip-us.apache.org/repos/asf/deltaspike/blob/27b756e0/deltaspike/test-utils/src/main/java/org/apache/deltaspike/test/category/WebEE7ProfileCategory.java
----------------------------------------------------------------------
diff --git a/deltaspike/test-utils/src/main/java/org/apache/deltaspike/test/category/WebEE7ProfileCategory.java b/deltaspike/test-utils/src/main/java/org/apache/deltaspike/test/category/WebEE7ProfileCategory.java
new file mode 100644
index 0000000..ef9141d
--- /dev/null
+++ b/deltaspike/test-utils/src/main/java/org/apache/deltaspike/test/category/WebEE7ProfileCategory.java
@@ -0,0 +1,27 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you 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.apache.deltaspike.test.category;
+
+/**
+ * Category marker interface. Tests which are Web profile minimum.
+ */
+public interface WebEE7ProfileCategory
+{
+}