Author: pete.muir(a)jboss.org
Date: 2009-03-08 18:33:13 -0400 (Sun, 08 Mar 2009)
New Revision: 1822
Added:
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/AbstractConversationTest.java
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/ClientConversationContextTest.java
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/Cloud.java
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/CloudController.java
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/ConversationStatusServlet.java
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/ConversationTestPhaseListener.java
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/InvalidatingSessionDestroysConversationTest.java
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/LongRunningConversationPropagatedByFacesContextTest.java
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/LongRunningInstancesNotDestroyedTest.java
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/Storm.java
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/cloud.jsf
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/clouds.jsf
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/faces-config.xml
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/home.jsf
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/lightening.jsf
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/rain.jsf
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/storm.jsf
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/thunder.jsf
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/web.xml
Removed:
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/AbstractConversationTest.java
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/Cloud.java
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/CloudController.java
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/ConversationStatusServlet.java
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/InvalidatingSessionDestroysConversationTest.java
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/LongRunningInstancesNotDestroyedTest.java
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/MultiRequestConversationContextTest.java
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/beans.xml
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/cloud.jsf
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/clouds.jsf
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/home.jsf
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/web.xml
Modified:
tck/trunk/impl/pom.xml
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/ConversationContextTest.java
tck/trunk/impl/src/main/resources/tck-audit.xml
tck/trunk/pom.xml
Log:
conversation tests
Modified: tck/trunk/impl/pom.xml
===================================================================
--- tck/trunk/impl/pom.xml 2009-03-08 22:23:49 UTC (rev 1821)
+++ tck/trunk/impl/pom.xml 2009-03-08 22:33:13 UTC (rev 1822)
@@ -91,6 +91,11 @@
<groupId>commons-httpclient</groupId>
<artifactId>commons-httpclient</artifactId>
</dependency>
+
+ <dependency>
+ <groupId>net.sourceforge.htmlunit</groupId>
+ <artifactId>htmlunit</artifactId>
+ </dependency>
</dependencies>
Deleted:
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/AbstractConversationTest.java
===================================================================
---
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/AbstractConversationTest.java 2009-03-08
22:23:49 UTC (rev 1821)
+++
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/AbstractConversationTest.java 2009-03-08
22:33:13 UTC (rev 1822)
@@ -1,109 +0,0 @@
-package org.jboss.jsr299.tck.tests.context.conversation;
-
-import java.io.ObjectInputStream;
-import java.net.MalformedURLException;
-import java.net.URL;
-
-import org.apache.commons.httpclient.HttpClient;
-import org.apache.commons.httpclient.HttpMethod;
-import org.apache.commons.httpclient.methods.GetMethod;
-import org.jboss.jsr299.tck.AbstractDeclarativeTest;
-
-public abstract class AbstractConversationTest extends AbstractDeclarativeTest
-{
-
- private static final long TIMEOUT = 200;
-
- protected String getCid(HttpClient client) throws Exception
- {
- HttpMethod method = new GetMethod(getConversationStatusPath("cid"));
- ObjectInputStream ois = null;
- try
- {
- client.executeMethod(method);
- ois = new ObjectInputStream(method.getResponseBodyAsStream());
- return (String) ois.readObject();
- }
- finally
- {
- if (ois != null)
- {
- ois.close();
- }
- method.releaseConnection();
- }
-
- }
-
- protected boolean isCloudDestroyed(HttpClient client) throws Exception
- {
- HttpMethod method = new
GetMethod(getConversationStatusPath("cloudDestroyed"));
- try
- {
- client.executeMethod(method);
- if (method.getStatusCode() == 200)
- {
- return true;
- }
- else
- {
- return false;
- }
- }
- finally
- {
- method.releaseConnection();
- }
- }
-
- protected void resetCloud(HttpClient client) throws Exception
- {
- HttpMethod method = new
GetMethod(getConversationStatusPath("resetCloud"));
- try
- {
- client.executeMethod(method);
- }
- finally
- {
- method.releaseConnection();
- }
- }
-
- protected void invalidateSession(HttpClient client) throws Exception
- {
- HttpMethod method = new
GetMethod(getConversationStatusPath("invalidateSession"));
- try
- {
- client.executeMethod(method);
- }
- finally
- {
- method.releaseConnection();
- }
- }
-
- protected String getConversationStatusPath(String method)
- {
- return super.getContextPath() + "conversation-status?method=" + method;
- }
-
- protected URL getConversationStatusURL(String method) throws MalformedURLException
- {
- return new URL(getConversationStatusPath(method));
- }
-
- protected void request(HttpClient client, String viewId) throws Exception
- {
- HttpMethod method = new GetMethod(getContextPath() + viewId);
- try
- {
- client.executeMethod(method);
- assert method.getStatusCode() == 200;
- }
- finally
- {
- method.releaseConnection();
- }
- }
-
-}
Deleted:
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/Cloud.java
===================================================================
---
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/Cloud.java 2009-03-08
22:23:49 UTC (rev 1821)
+++
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/Cloud.java 2009-03-08
22:33:13 UTC (rev 1822)
@@ -1,37 +0,0 @@
-package org.jboss.jsr299.tck.tests.context.conversation;
-
-import java.io.Serializable;
-
-import javax.annotation.Named;
-import javax.annotation.PreDestroy;
-import javax.context.ConversationScoped;
-
-@ConversationScoped
-@Named
-public class Cloud implements Serializable
-{
-
- private static boolean destroyed = false;
-
- @PreDestroy
- public void destroy()
- {
- destroyed = true;
- }
-
- public static boolean isDestroyed()
- {
- return destroyed;
- }
-
- public static void setDestroyed(boolean destroyed)
- {
- Cloud.destroyed = destroyed;
- }
-
- public String getName()
- {
- return "Pete";
- }
-
-}
Deleted:
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/CloudController.java
===================================================================
---
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/CloudController.java 2009-03-08
22:23:49 UTC (rev 1821)
+++
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/CloudController.java 2009-03-08
22:33:13 UTC (rev 1822)
@@ -1,19 +0,0 @@
-package org.jboss.jsr299.tck.tests.context.conversation;
-
-import javax.annotation.Named;
-import javax.context.Conversation;
-import javax.inject.Current;
-
-@Named
-public class CloudController
-{
-
- @Current Conversation conversation;
-
- public String getBeginConversation()
- {
- conversation.begin();
- return "begun conversation";
- }
-
-}
Modified:
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/ConversationContextTest.java
===================================================================
---
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/ConversationContextTest.java 2009-03-08
22:23:49 UTC (rev 1821)
+++
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/ConversationContextTest.java 2009-03-08
22:33:13 UTC (rev 1822)
@@ -19,6 +19,7 @@
* Spec version: PRD2
*/
@Artifact
+
public class ConversationContextTest extends AbstractDeclarativeTest
{
Deleted:
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/ConversationStatusServlet.java
===================================================================
---
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/ConversationStatusServlet.java 2009-03-08
22:23:49 UTC (rev 1821)
+++
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/ConversationStatusServlet.java 2009-03-08
22:33:13 UTC (rev 1822)
@@ -1,58 +0,0 @@
-package org.jboss.jsr299.tck.tests.context.conversation;
-
-import java.io.IOException;
-import java.io.ObjectOutputStream;
-
-import javax.context.Conversation;
-import javax.servlet.ServletException;
-import javax.servlet.http.HttpServlet;
-import javax.servlet.http.HttpServletRequest;
-import javax.servlet.http.HttpServletResponse;
-
-import org.jboss.jsr299.tck.impl.ConfigurationImpl;
-
-public class ConversationStatusServlet extends HttpServlet
-{
-
- @Override
- protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws
ServletException, IOException
- {
- String method = req.getParameter("method");
- if ("cid".equals(method))
- {
-
serializeToResponse(ConfigurationImpl.get().getManagers().getManager().getInstanceByType(Conversation.class).getId(),
resp);
- }
- else if ("cloudDestroyed".equals(method))
- {
- if (Cloud.isDestroyed())
- {
- resp.setStatus(HttpServletResponse.SC_OK);
- }
- else
- {
- resp.sendError(HttpServletResponse.SC_INTERNAL_SERVER_ERROR);
- }
- }
- else if ("invalidateSession".equals(method))
- {
- req.getSession().invalidate();
- }
- else if ("resetCloud".equals(method))
- {
- Cloud.setDestroyed(false);
- }
- else
- {
- resp.sendError(HttpServletResponse.SC_INTERNAL_SERVER_ERROR);
- }
- }
-
- private void serializeToResponse(Object object, HttpServletResponse resp) throws
IOException
- {
- ObjectOutputStream oos = new ObjectOutputStream(resp.getOutputStream());
- oos.writeObject(object);
- oos.flush();
- oos.close();
- }
-
-}
Deleted:
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/InvalidatingSessionDestroysConversationTest.java
===================================================================
---
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/InvalidatingSessionDestroysConversationTest.java 2009-03-08
22:23:49 UTC (rev 1821)
+++
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/InvalidatingSessionDestroysConversationTest.java 2009-03-08
22:33:13 UTC (rev 1822)
@@ -1,40 +0,0 @@
-package org.jboss.jsr299.tck.tests.context.conversation;
-
-import org.apache.commons.httpclient.HttpClient;
-import org.hibernate.tck.annotations.SpecAssertion;
-import org.jboss.jsr299.tck.impl.packaging.Artifact;
-import org.jboss.jsr299.tck.impl.packaging.IntegrationTest;
-import org.jboss.jsr299.tck.impl.packaging.Resource;
-import org.jboss.jsr299.tck.impl.packaging.Resources;
-import org.jboss.jsr299.tck.impl.packaging.war.WarArtifactDescriptor;
-import org.testng.annotations.Test;
-
-/**
- *
- * @author Nicklas Karlsson
- *
- * Spec version: PRD2
- */
-@Artifact
-@IntegrationTest(runLocally=true)
-@Resources({
- @Resource(destination=WarArtifactDescriptor.WEB_XML_DESTINATION,
source="web.xml"),
- @Resource(destination="clouds.jspx", source="clouds.jsf"),
- @Resource(destination="cloud.jspx", source="cloud.jsf")
-})
-public class InvalidatingSessionDestroysConversationTest extends
AbstractConversationTest
-{
-
- @Test(groups = { "contexts" })
- @SpecAssertion(section = "8.5.4", id = "a")
- public void testInvalidatingSessionDestroysConversation() throws Exception
- {
- HttpClient client = new HttpClient();
- resetCloud(client);
- request(client, "/clouds.jsf");
- assert !isCloudDestroyed(client);
- invalidateSession(client);
- assert isCloudDestroyed(client);
- }
-
-}
\ No newline at end of file
Deleted:
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/LongRunningInstancesNotDestroyedTest.java
===================================================================
---
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/LongRunningInstancesNotDestroyedTest.java 2009-03-08
22:23:49 UTC (rev 1821)
+++
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/LongRunningInstancesNotDestroyedTest.java 2009-03-08
22:33:13 UTC (rev 1822)
@@ -1,38 +0,0 @@
-package org.jboss.jsr299.tck.tests.context.conversation;
-
-import org.apache.commons.httpclient.HttpClient;
-import org.hibernate.tck.annotations.SpecAssertion;
-import org.jboss.jsr299.tck.impl.packaging.Artifact;
-import org.jboss.jsr299.tck.impl.packaging.IntegrationTest;
-import org.jboss.jsr299.tck.impl.packaging.Resource;
-import org.jboss.jsr299.tck.impl.packaging.Resources;
-import org.jboss.jsr299.tck.impl.packaging.war.WarArtifactDescriptor;
-import org.testng.annotations.Test;
-
-/**
- *
- * @author Nicklas Karlsson
- *
- * Spec version: PRD2
- */
-@Artifact
-@IntegrationTest(runLocally=true)
-@Resources({
- @Resource(destination=WarArtifactDescriptor.WEB_XML_DESTINATION,
source="web.xml"),
- @Resource(destination="clouds.jspx", source="clouds.jsf"),
- @Resource(destination="cloud.jspx", source="cloud.jsf")
-})
-public class LongRunningInstancesNotDestroyedTest extends AbstractConversationTest
-{
-
- @Test(groups = { "contexts" })
- @SpecAssertion(section = "8.5.4", id = "k")
- public void testLongRunningConversationInstancesNotDestroyedAtRequestEnd() throws
Exception
- {
- HttpClient client = new HttpClient();
- resetCloud(client);
- request(client, "/clouds.jsf");
- assert !isCloudDestroyed(client);
- }
-
-}
\ No newline at end of file
Deleted:
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/MultiRequestConversationContextTest.java
===================================================================
---
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/MultiRequestConversationContextTest.java 2009-03-08
22:23:49 UTC (rev 1821)
+++
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/MultiRequestConversationContextTest.java 2009-03-08
22:33:13 UTC (rev 1822)
@@ -1,61 +0,0 @@
-package org.jboss.jsr299.tck.tests.context.conversation;
-
-import org.apache.commons.httpclient.HttpClient;
-import org.hibernate.tck.annotations.SpecAssertion;
-import org.jboss.jsr299.tck.impl.packaging.Artifact;
-import org.jboss.jsr299.tck.impl.packaging.IntegrationTest;
-import org.jboss.jsr299.tck.impl.packaging.Resource;
-import org.jboss.jsr299.tck.impl.packaging.Resources;
-import org.jboss.jsr299.tck.impl.packaging.war.WarArtifactDescriptor;
-import org.testng.annotations.Test;
-
-/**
- *
- * @author Nicklas Karlsson
- *
- * Spec version: PRD2
- */
-@Artifact
-@IntegrationTest(runLocally=true)
-@Resources({
- @Resource(destination=WarArtifactDescriptor.WEB_XML_DESTINATION,
source="web.xml"),
- @Resource(destination="home.jspx", source="home.jsf"),
- @Resource(destination="cloud.jspx", source="cloud.jsf"),
- @Resource(destination="clouds.jspx", source="clouds.jsf")
-})
-public class MultiRequestConversationContextTest extends AbstractConversationTest
-{
-
- @Test(groups = { "contexts" })
- @SpecAssertion(section = "8.5.4", id = "hb")
- public void testConversationIdSetByContainerIsUnique() throws Exception
- {
- HttpClient client = new HttpClient();
- request(client, "/home.jsf");
- String cid1 = getCid(client);
- request(client, "/home.jsf");
- String cid2 = getCid(client);
- assert !cid1.equals(cid2);
- }
-
- @Test(groups = { "contexts" })
- @SpecAssertion(section = "8.5.4", id = "j")
- public void testTransientConversationInstancesDestroyedAtRequestEnd() throws
Exception
- {
- HttpClient client = new HttpClient();
- resetCloud(client);
- request(client, "/cloud.jsf");
- assert isCloudDestroyed(client);
- }
-
- @Test(groups = { "contexts" })
- @SpecAssertion(section = "8.5.4", id = "k")
- public void testLongRunningConversationInstancesNotDestroyedAtRequestEnd() throws
Exception
- {
- HttpClient client = new HttpClient();
- resetCloud(client);
- request(client, "/clouds.jsf");
- assert !isCloudDestroyed(client);
- }
-
-}
\ No newline at end of file
Copied:
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/AbstractConversationTest.java
(from rev 1818,
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/AbstractConversationTest.java)
===================================================================
---
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/AbstractConversationTest.java
(rev 0)
+++
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/AbstractConversationTest.java 2009-03-08
22:33:13 UTC (rev 1822)
@@ -0,0 +1,205 @@
+package org.jboss.jsr299.tck.tests.context.conversation.client;
+
+import java.io.ObjectInputStream;
+import java.net.MalformedURLException;
+import java.net.URL;
+import java.util.HashSet;
+import java.util.Set;
+
+import org.apache.commons.httpclient.HttpClient;
+import org.apache.commons.httpclient.HttpMethod;
+import org.apache.commons.httpclient.methods.GetMethod;
+import org.jboss.jsr299.tck.AbstractDeclarativeTest;
+
+import com.gargoylesoftware.htmlunit.html.HtmlElement;
+import com.gargoylesoftware.htmlunit.html.HtmlPage;
+
+public abstract class AbstractConversationTest extends AbstractDeclarativeTest
+{
+
+ public static final String CID_HEADER_NAME = "org.jboss.jsr299.tck.cid";
+
+ private static final long TIMEOUT = 200;
+
+ protected String getCid(HttpClient client) throws Exception
+ {
+ HttpMethod method = new GetMethod(getConversationStatusPath("cid"));
+ ObjectInputStream ois = null;
+ try
+ {
+ client.executeMethod(method);
+ ois = new ObjectInputStream(method.getResponseBodyAsStream());
+ return (String) ois.readObject();
+ }
+ finally
+ {
+ if (ois != null)
+ {
+ ois.close();
+ }
+ method.releaseConnection();
+ }
+ }
+
+
+
+ protected boolean isCloudDestroyed(HttpClient client) throws Exception
+ {
+ HttpMethod method = new
GetMethod(getConversationStatusPath("cloudDestroyed"));
+ try
+ {
+ client.executeMethod(method);
+ if (method.getStatusCode() == 200)
+ {
+ return true;
+ }
+ else
+ {
+ return false;
+ }
+ }
+ finally
+ {
+ method.releaseConnection();
+ }
+ }
+
+ protected void resetCloud(HttpClient client) throws Exception
+ {
+ HttpMethod method = new
GetMethod(getConversationStatusPath("resetCloud"));
+ try
+ {
+ client.executeMethod(method);
+ }
+ finally
+ {
+ method.releaseConnection();
+ }
+ }
+
+ protected void invalidateSession(HttpClient client) throws Exception
+ {
+ HttpMethod method = new
GetMethod(getConversationStatusPath("invalidateSession"));
+ try
+ {
+ client.executeMethod(method);
+ }
+ finally
+ {
+ method.releaseConnection();
+ }
+ }
+
+ protected String getConversationStatusPath(String method)
+ {
+ return super.getContextPath() + "conversation-status?method=" + method;
+ }
+
+ protected URL getConversationStatusURL(String method) throws MalformedURLException
+ {
+ return new URL(getConversationStatusPath(method));
+ }
+
+ protected String request(HttpClient client, String viewId) throws Exception
+ {
+ HttpMethod method = new GetMethod(getPath(viewId));
+ try
+ {
+ client.executeMethod(method);
+ assert method.getStatusCode() == 200;
+ return method.getResponseHeader(CID_HEADER_NAME).getValue();
+ }
+ finally
+ {
+ method.releaseConnection();
+ }
+ }
+
+ protected String getBodyAsString(HttpClient client, String viewId) throws Exception
+ {
+ HttpMethod method = new GetMethod(getPath(viewId));
+ try
+ {
+ client.executeMethod(method);
+ assert method.getStatusCode() == 200;
+ return method.getResponseBodyAsString();
+ }
+ finally
+ {
+ method.releaseConnection();
+ }
+ }
+
+ protected boolean hasRained(HttpClient client, String viewId) throws Exception
+ {
+ HttpMethod method = new GetMethod(getPath(viewId));
+ try
+ {
+ client.executeMethod(method);
+ assert method.getStatusCode() == 200;
+ return
method.getResponseHeader(Cloud.RAINED_HEADER_NAME).getValue().equals("true") ?
true : false;
+ }
+ finally
+ {
+ method.releaseConnection();
+ }
+ }
+
+ protected String getPath(String viewId)
+ {
+ return getContextPath() + viewId;
+ }
+
+ protected boolean isActiveBeforeApplyRequestValues(HttpClient client, String viewId)
throws Exception
+ {
+ HttpMethod method = new GetMethod(getPath(viewId));
+ try
+ {
+ client.executeMethod(method);
+ assert method.getStatusCode() == 200;
+ return
Boolean.valueOf(method.getResponseHeader(ConversationTestPhaseListener.ACTIVE_BEFORE_APPLY_REQUEST_VALUES_HEADER_NAME).getValue());
+ }
+ finally
+ {
+ method.releaseConnection();
+ }
+ }
+
+ protected <T> Set<T> getElements(HtmlElement rootElement, Class<T>
elementClass)
+ {
+ Set<T> result = new HashSet<T>();
+
+ for (HtmlElement element : rootElement.getAllHtmlChildElements())
+ {
+ result.addAll(getElements(element, elementClass));
+ }
+
+ if (elementClass.isInstance(rootElement))
+ {
+ result.add(elementClass.cast(rootElement));
+ }
+ return result;
+
+ }
+
+ protected <T extends HtmlElement> T getFirstMatchingElement(HtmlPage page,
Class<T> elementClass, String id)
+ {
+
+ Set<T> inputs = getElements(page.getBody(), elementClass);
+ for (T input : inputs)
+ {
+ if (input.getId().contains(id))
+ {
+ return input;
+ }
+ }
+ return null;
+ }
+
+ protected String getCid(HtmlPage page)
+ {
+ return
page.getWebResponse().getResponseHeaderValue(AbstractConversationTest.CID_HEADER_NAME);
+ }
+
+
+}
Property changes on:
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/AbstractConversationTest.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Copied:
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/ClientConversationContextTest.java
(from rev 1815,
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/MultiRequestConversationContextTest.java)
===================================================================
---
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/ClientConversationContextTest.java
(rev 0)
+++
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/ClientConversationContextTest.java 2009-03-08
22:33:13 UTC (rev 1822)
@@ -0,0 +1,112 @@
+package org.jboss.jsr299.tck.tests.context.conversation.client;
+
+import org.apache.commons.httpclient.HttpClient;
+import org.hibernate.tck.annotations.SpecAssertion;
+import org.jboss.jsr299.tck.impl.packaging.Artifact;
+import org.jboss.jsr299.tck.impl.packaging.Classes;
+import org.jboss.jsr299.tck.impl.packaging.IntegrationTest;
+import org.jboss.jsr299.tck.impl.packaging.Resource;
+import org.jboss.jsr299.tck.impl.packaging.Resources;
+import org.jboss.jsr299.tck.impl.packaging.war.WarArtifactDescriptor;
+import org.testng.annotations.Test;
+
+/**
+ *
+ * @author Nicklas Karlsson
+ *
+ * Spec version: PRD2
+ */
+@Artifact(addCurrentPackage=false)
+(a)Classes({Storm.class, ConversationTestPhaseListener.class,
ConversationStatusServlet.class, Cloud.class, CloudController.class})
+@IntegrationTest(runLocally=true)
+@Resources({
+ @Resource(destination=WarArtifactDescriptor.WEB_XML_DESTINATION,
source="web.xml"),
+ @Resource(destination="home.jspx", source="home.jsf"),
+ @Resource(destination="cloud.jspx", source="cloud.jsf"),
+ @Resource(destination="clouds.jspx", source="clouds.jsf"),
+ @Resource(destination="/WEB-INF/faces-config.xml",
source="faces-config.xml"),
+ @Resource(destination="rain.jspx", source="rain.jsf")
+})
+public class ClientConversationContextTest extends AbstractConversationTest
+{
+
+ @Test(groups = { "contexts" })
+ @SpecAssertion(section = "8.5.4", id = "hb")
+ public void testConversationIdSetByContainerIsUnique() throws Exception
+ {
+ HttpClient client = new HttpClient();
+ request(client, "/home.jsf");
+ String cid1 = getCid(client);
+ request(client, "/home.jsf");
+ String cid2 = getCid(client);
+ assert !cid1.equals(cid2);
+ }
+
+ @Test(groups = { "contexts" })
+ @SpecAssertion(section = "8.5.4", id = "j")
+ public void testTransientConversationInstancesDestroyedAtRequestEnd() throws
Exception
+ {
+ HttpClient client = new HttpClient();
+ resetCloud(client);
+ request(client, "/cloud.jsf");
+ assert isCloudDestroyed(client);
+ }
+
+ @Test(groups = { "contexts" })
+ @SpecAssertion(section = "8.5.4", id = "k")
+ public void testLongRunningConversationInstancesNotDestroyedAtRequestEnd() throws
Exception
+ {
+ HttpClient client = new HttpClient();
+ resetCloud(client);
+ request(client, "/clouds.jsf");
+ assert !isCloudDestroyed(client);
+ }
+
+ @Test(groups = { "contexts" })
+ @SpecAssertion(section = "8.5.4", id = "n")
+ public void testManualCidPropagation() throws Exception
+ {
+ HttpClient client = new HttpClient();
+ String cid = request(client, "/clouds.jsf");
+ String cid2 = request(client, "/clouds.jsf?cid=" + cid);
+ assert cid.equals(cid2);
+ }
+
+ @Test(groups = { "contexts" })
+ @SpecAssertion(section = "8.5.4", id = "o")
+ public void testConversationNotPropagated() throws Exception
+ {
+ HttpClient client = new HttpClient();
+ String cid = request(client, "/clouds.jsf");
+ String cid2 = request(client, "/clouds.jsf");
+ assert !cid.equals(cid2);
+ }
+
+ @Test(groups = { "contexts" })
+ @SpecAssertion(section = "8.5.4", id = "p")
+ public void testConversationsDontCrossSessionBoundary() throws Exception
+ {
+ HttpClient client = new HttpClient();
+ String cid = request(client, "/rain.jsf");
+ assert hasRained(client, "/cloud.jsf?cid=" + cid);
+ invalidateSession(client);
+ assert !hasRained(client, "/cloud.jsf?cid=" + cid);
+ }
+
+ @Test(groups = { "contexts" })
+ @SpecAssertion(section = "8.5.4", id = "b")
+ public void testConversationActiveDuringNonFacesRequest() throws Exception
+ {
+ HttpClient client = new HttpClient();
+ assert getBodyAsString(client, "/cloud.jsf").contains(Cloud.NAME);
+ }
+
+ @Test(groups = { "contexts" })
+ @SpecAssertion(section = "8.5.4", id = "s")
+ public void
testConversationPropagationToNonExistentConversationLeadsToTransientConversation() throws
Exception
+ {
+ HttpClient client = new HttpClient();
+ assert !request(client,
"/cloud.jsf?cid=org.jboss.jsr299").equals("org.jboss.jsr299");
+ }
+
+}
\ No newline at end of file
Property changes on:
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/ClientConversationContextTest.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Copied:
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/Cloud.java
(from rev 1818,
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/Cloud.java)
===================================================================
---
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/Cloud.java
(rev 0)
+++
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/Cloud.java 2009-03-08
22:33:13 UTC (rev 1822)
@@ -0,0 +1,54 @@
+package org.jboss.jsr299.tck.tests.context.conversation.client;
+
+import java.io.Serializable;
+
+import javax.annotation.Named;
+import javax.annotation.PreDestroy;
+import javax.context.ConversationScoped;
+
+@ConversationScoped
+@Named
+public class Cloud implements Serializable
+{
+
+ public static final String NAME = Cloud.class.getName() + ".Pete";
+
+ public static final String RAINED_HEADER_NAME = Cloud.class.getName() +
".rained";
+
+ private static boolean destroyed = false;
+
+ private boolean rained;
+
+ @PreDestroy
+ public void destroy()
+ {
+ destroyed = true;
+ }
+
+ public static boolean isDestroyed()
+ {
+ return destroyed;
+ }
+
+ public static void setDestroyed(boolean destroyed)
+ {
+ Cloud.destroyed = destroyed;
+ }
+
+ public String getName()
+ {
+ return NAME;
+ }
+
+ public String getRain()
+ {
+ rained = true;
+ return "rain!";
+ }
+
+ public boolean isRained()
+ {
+ return rained;
+ }
+
+}
Property changes on:
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/Cloud.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Copied:
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/CloudController.java
(from rev 1818,
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/CloudController.java)
===================================================================
---
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/CloudController.java
(rev 0)
+++
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/CloudController.java 2009-03-08
22:33:13 UTC (rev 1822)
@@ -0,0 +1,19 @@
+package org.jboss.jsr299.tck.tests.context.conversation.client;
+
+import javax.annotation.Named;
+import javax.context.Conversation;
+import javax.inject.Current;
+
+@Named
+public class CloudController
+{
+
+ @Current Conversation conversation;
+
+ public String getBeginConversation()
+ {
+ conversation.begin();
+ return "begun conversation";
+ }
+
+}
Property changes on:
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/CloudController.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Copied:
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/ConversationStatusServlet.java
(from rev 1818,
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/ConversationStatusServlet.java)
===================================================================
---
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/ConversationStatusServlet.java
(rev 0)
+++
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/ConversationStatusServlet.java 2009-03-08
22:33:13 UTC (rev 1822)
@@ -0,0 +1,58 @@
+package org.jboss.jsr299.tck.tests.context.conversation.client;
+
+import java.io.IOException;
+import java.io.ObjectOutputStream;
+
+import javax.context.Conversation;
+import javax.servlet.ServletException;
+import javax.servlet.http.HttpServlet;
+import javax.servlet.http.HttpServletRequest;
+import javax.servlet.http.HttpServletResponse;
+
+import org.jboss.jsr299.tck.impl.ConfigurationImpl;
+
+public class ConversationStatusServlet extends HttpServlet
+{
+
+ @Override
+ protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws
ServletException, IOException
+ {
+ String method = req.getParameter("method");
+ if ("cid".equals(method))
+ {
+
serializeToResponse(ConfigurationImpl.get().getManagers().getManager().getInstanceByType(Conversation.class).getId(),
resp);
+ }
+ else if ("cloudDestroyed".equals(method))
+ {
+ if (Cloud.isDestroyed())
+ {
+ resp.setStatus(HttpServletResponse.SC_OK);
+ }
+ else
+ {
+ resp.sendError(HttpServletResponse.SC_INTERNAL_SERVER_ERROR);
+ }
+ }
+ else if ("invalidateSession".equals(method))
+ {
+ req.getSession().invalidate();
+ }
+ else if ("resetCloud".equals(method))
+ {
+ Cloud.setDestroyed(false);
+ }
+ else
+ {
+ resp.sendError(HttpServletResponse.SC_INTERNAL_SERVER_ERROR);
+ }
+ }
+
+ private void serializeToResponse(Object object, HttpServletResponse resp) throws
IOException
+ {
+ ObjectOutputStream oos = new ObjectOutputStream(resp.getOutputStream());
+ oos.writeObject(object);
+ oos.flush();
+ oos.close();
+ }
+
+}
Property changes on:
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/ConversationStatusServlet.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added:
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/ConversationTestPhaseListener.java
===================================================================
---
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/ConversationTestPhaseListener.java
(rev 0)
+++
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/ConversationTestPhaseListener.java 2009-03-08
22:33:13 UTC (rev 1822)
@@ -0,0 +1,52 @@
+package org.jboss.jsr299.tck.tests.context.conversation.client;
+
+import javax.context.ContextNotActiveException;
+import javax.context.Conversation;
+import javax.context.ConversationScoped;
+import javax.faces.event.PhaseEvent;
+import javax.faces.event.PhaseId;
+import javax.faces.event.PhaseListener;
+import javax.servlet.http.HttpServletResponse;
+
+import org.jboss.jsr299.tck.impl.ConfigurationImpl;
+
+public class ConversationTestPhaseListener implements PhaseListener
+{
+
+ public static final String ACTIVE_BEFORE_APPLY_REQUEST_VALUES_HEADER_NAME =
"org.jboss.jsr299.tck.activeBeforeApplyRequestValues";
+
+ private boolean activeBeforeApplyRequestValues;
+
+ public void afterPhase(PhaseEvent event)
+ {
+ }
+
+ public void beforePhase(PhaseEvent event)
+ {
+ if (event.getPhaseId().equals(PhaseId.APPLY_REQUEST_VALUES))
+ {
+ try
+ {
+
ConfigurationImpl.get().getManagers().getManager().getContext(ConversationScoped.class);
+ activeBeforeApplyRequestValues = true;
+ }
+ catch (ContextNotActiveException e)
+ {
+ activeBeforeApplyRequestValues = false;
+ }
+ }
+ if (event.getPhaseId().equals(PhaseId.RENDER_RESPONSE))
+ {
+ HttpServletResponse response = (HttpServletResponse)
event.getFacesContext().getExternalContext().getResponse();
+ response.addHeader(AbstractConversationTest.CID_HEADER_NAME,
ConfigurationImpl.get().getManagers().getManager().getInstanceByType(Conversation.class).getId());
+ response.addHeader(Cloud.RAINED_HEADER_NAME, new
Boolean(ConfigurationImpl.get().getManagers().getManager().getInstanceByType(Cloud.class).isRained()).toString());
+ response.addHeader(ACTIVE_BEFORE_APPLY_REQUEST_VALUES_HEADER_NAME, new
Boolean(activeBeforeApplyRequestValues).toString());
+ }
+ }
+
+ public PhaseId getPhaseId()
+ {
+ return PhaseId.ANY_PHASE;
+ }
+
+}
Property changes on:
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/ConversationTestPhaseListener.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Copied:
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/InvalidatingSessionDestroysConversationTest.java
(from rev 1818,
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/InvalidatingSessionDestroysConversationTest.java)
===================================================================
---
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/InvalidatingSessionDestroysConversationTest.java
(rev 0)
+++
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/InvalidatingSessionDestroysConversationTest.java 2009-03-08
22:33:13 UTC (rev 1822)
@@ -0,0 +1,43 @@
+package org.jboss.jsr299.tck.tests.context.conversation.client;
+
+import org.apache.commons.httpclient.HttpClient;
+import org.hibernate.tck.annotations.SpecAssertion;
+import org.jboss.jsr299.tck.impl.packaging.Artifact;
+import org.jboss.jsr299.tck.impl.packaging.Classes;
+import org.jboss.jsr299.tck.impl.packaging.IntegrationTest;
+import org.jboss.jsr299.tck.impl.packaging.Resource;
+import org.jboss.jsr299.tck.impl.packaging.Resources;
+import org.jboss.jsr299.tck.impl.packaging.war.WarArtifactDescriptor;
+import org.testng.annotations.Test;
+
+/**
+ *
+ * @author Nicklas Karlsson
+ *
+ * Spec version: PRD2
+ */
+@Artifact(addCurrentPackage=false)
+(a)Classes({Storm.class, ConversationTestPhaseListener.class,
ConversationStatusServlet.class, Cloud.class, CloudController.class})
+@IntegrationTest(runLocally=true)
+@Resources({
+ @Resource(destination=WarArtifactDescriptor.WEB_XML_DESTINATION,
source="web.xml"),
+ @Resource(destination="WEB-INF/faces-config.xml",
source="faces-config.xml"),
+ @Resource(destination="clouds.jspx", source="clouds.jsf"),
+ @Resource(destination="cloud.jspx", source="cloud.jsf")
+})
+public class InvalidatingSessionDestroysConversationTest extends
AbstractConversationTest
+{
+
+ @Test(groups = { "contexts" })
+ @SpecAssertion(section = "8.5.4", id = "q")
+ public void testInvalidatingSessionDestroysConversation() throws Exception
+ {
+ HttpClient client = new HttpClient();
+ resetCloud(client);
+ request(client, "/clouds.jsf");
+ assert !isCloudDestroyed(client);
+ invalidateSession(client);
+ assert isCloudDestroyed(client);
+ }
+
+}
\ No newline at end of file
Property changes on:
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/InvalidatingSessionDestroysConversationTest.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added:
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/LongRunningConversationPropagatedByFacesContextTest.java
===================================================================
---
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/LongRunningConversationPropagatedByFacesContextTest.java
(rev 0)
+++
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/LongRunningConversationPropagatedByFacesContextTest.java 2009-03-08
22:33:13 UTC (rev 1822)
@@ -0,0 +1,76 @@
+package org.jboss.jsr299.tck.tests.context.conversation.client;
+
+import org.hibernate.tck.annotations.SpecAssertion;
+import org.jboss.jsr299.tck.impl.packaging.Artifact;
+import org.jboss.jsr299.tck.impl.packaging.Classes;
+import org.jboss.jsr299.tck.impl.packaging.IntegrationTest;
+import org.jboss.jsr299.tck.impl.packaging.Resource;
+import org.jboss.jsr299.tck.impl.packaging.Resources;
+import org.jboss.jsr299.tck.impl.packaging.war.WarArtifactDescriptor;
+import org.testng.annotations.Test;
+
+import com.gargoylesoftware.htmlunit.WebClient;
+import com.gargoylesoftware.htmlunit.html.HtmlPage;
+import com.gargoylesoftware.htmlunit.html.HtmlSubmitInput;
+import com.gargoylesoftware.htmlunit.html.HtmlTextInput;
+
+/**
+ *
+ * @author Nicklas Karlsson
+ *
+ * Spec version: PRD2
+ */
+@Artifact(addCurrentPackage=false)
+(a)Classes({Storm.class, ConversationTestPhaseListener.class,
ConversationStatusServlet.class, Cloud.class})
+@IntegrationTest(runLocally=true)
+@Resources({
+ @Resource(destination=WarArtifactDescriptor.WEB_XML_DESTINATION,
source="web.xml"),
+ @Resource(destination="WEB-INF/faces-config.xml",
source="faces-config.xml"),
+ @Resource(destination="storm.jspx", source="storm.jsf"),
+ @Resource(destination="thunder.jspx", source="thunder.jsf"),
+ @Resource(destination="lightening.jspx", source="lightening.jsf")
+})
+public class LongRunningConversationPropagatedByFacesContextTest extends
AbstractConversationTest
+{
+
+ private static final String STORM_STRENGTH = "12";
+ private static final String REDIRECT_STORM_STRENGTH = "15";
+
+ @Test(groups = { "contexts" })
+ @SpecAssertion(section = "8.5.4", id = "l")
+ public void testConversationPropagated() throws Exception
+ {
+ WebClient webClient = new WebClient();
+ HtmlPage storm = webClient.getPage(getPath("/storm.jsf"));
+ HtmlSubmitInput beginConversationButton = getFirstMatchingElement(storm,
HtmlSubmitInput.class, "beginConversationButton");
+ storm = beginConversationButton.click();
+ HtmlTextInput stormStrength = getFirstMatchingElement(storm, HtmlTextInput.class,
"stormStrength");
+ stormStrength.setValueAttribute(STORM_STRENGTH);
+ String stormCid = getCid(storm);
+ HtmlSubmitInput thunderButton = getFirstMatchingElement(storm,
HtmlSubmitInput.class, "thunderButton");
+ HtmlPage thunder = thunderButton.click();
+ assert stormCid.equals(getCid(thunder));
+ stormStrength = getFirstMatchingElement(thunder, HtmlTextInput.class,
"stormStrength");
+ assert stormStrength.getValueAttribute().equals(STORM_STRENGTH);
+ }
+
+ @Test(groups = { "contexts" })
+ @SpecAssertion(section = "8.5.4", id = "m")
+ public void testConversationPropagatedOverRedirect() throws Exception
+ {
+ WebClient webClient = new WebClient();
+ HtmlPage storm = webClient.getPage(getPath("/storm.jsf"));
+ HtmlSubmitInput beginConversationButton = getFirstMatchingElement(storm,
HtmlSubmitInput.class, "beginConversationButton");
+ storm = beginConversationButton.click();
+ HtmlTextInput stormStrength = getFirstMatchingElement(storm, HtmlTextInput.class,
"stormStrength");
+ stormStrength.setValueAttribute(REDIRECT_STORM_STRENGTH);
+ String stormCid = getCid(storm);
+ HtmlSubmitInput lighteningButton = getFirstMatchingElement(storm,
HtmlSubmitInput.class, "lighteningButton");
+ HtmlPage lightening = lighteningButton.click();
+ assert
lightening.getWebResponse().getRequestUrl().toString().contains("lightening.jsf");
+ assert stormCid.equals(getCid(lightening));
+ stormStrength = getFirstMatchingElement(lightening, HtmlTextInput.class,
"stormStrength");
+ assert stormStrength.getValueAttribute().equals(REDIRECT_STORM_STRENGTH);
+ }
+
+}
\ No newline at end of file
Property changes on:
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/LongRunningConversationPropagatedByFacesContextTest.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Copied:
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/LongRunningInstancesNotDestroyedTest.java
(from rev 1818,
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/LongRunningInstancesNotDestroyedTest.java)
===================================================================
---
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/LongRunningInstancesNotDestroyedTest.java
(rev 0)
+++
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/LongRunningInstancesNotDestroyedTest.java 2009-03-08
22:33:13 UTC (rev 1822)
@@ -0,0 +1,41 @@
+package org.jboss.jsr299.tck.tests.context.conversation.client;
+
+import org.apache.commons.httpclient.HttpClient;
+import org.hibernate.tck.annotations.SpecAssertion;
+import org.jboss.jsr299.tck.impl.packaging.Artifact;
+import org.jboss.jsr299.tck.impl.packaging.Classes;
+import org.jboss.jsr299.tck.impl.packaging.IntegrationTest;
+import org.jboss.jsr299.tck.impl.packaging.Resource;
+import org.jboss.jsr299.tck.impl.packaging.Resources;
+import org.jboss.jsr299.tck.impl.packaging.war.WarArtifactDescriptor;
+import org.testng.annotations.Test;
+
+/**
+ *
+ * @author Nicklas Karlsson
+ *
+ * Spec version: PRD2
+ */
+@Artifact(addCurrentPackage=false)
+(a)Classes({Storm.class, ConversationTestPhaseListener.class,
ConversationStatusServlet.class, Cloud.class, CloudController.class})
+@IntegrationTest(runLocally=true)
+@Resources({
+ @Resource(destination=WarArtifactDescriptor.WEB_XML_DESTINATION,
source="web.xml"),
+ @Resource(destination="clouds.jspx", source="clouds.jsf"),
+ @Resource(destination="WEB-INF/faces-config.xml",
source="faces-config.xml"),
+ @Resource(destination="cloud.jspx", source="cloud.jsf")
+})
+public class LongRunningInstancesNotDestroyedTest extends AbstractConversationTest
+{
+
+ @Test(groups = { "contexts" })
+ @SpecAssertion(section = "8.5.4", id = "k")
+ public void testLongRunningConversationInstancesNotDestroyedAtRequestEnd() throws
Exception
+ {
+ HttpClient client = new HttpClient();
+ resetCloud(client);
+ request(client, "/clouds.jsf");
+ assert !isCloudDestroyed(client);
+ }
+
+}
\ No newline at end of file
Property changes on:
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/LongRunningInstancesNotDestroyedTest.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added:
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/Storm.java
===================================================================
---
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/Storm.java
(rev 0)
+++
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/Storm.java 2009-03-08
22:33:13 UTC (rev 1822)
@@ -0,0 +1,44 @@
+package org.jboss.jsr299.tck.tests.context.conversation.client;
+
+import java.io.Serializable;
+
+import javax.annotation.Named;
+import javax.context.Conversation;
+import javax.context.ConversationScoped;
+import javax.inject.Current;
+
+@Named
+@ConversationScoped
+public class Storm implements Serializable
+{
+
+ @Current Conversation conversation;
+
+ private String strength;
+
+ public String thunder()
+ {
+ return "thunder";
+ }
+
+ public String lightening()
+ {
+ return "lightening";
+ }
+
+ public void beginConversation()
+ {
+ conversation.begin();
+ }
+
+ public String getStrength()
+ {
+ return strength;
+ }
+
+ public void setStrength(String strength)
+ {
+ this.strength = strength;
+ }
+
+}
Property changes on:
tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/conversation/client/Storm.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Deleted:
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/beans.xml
===================================================================
---
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/beans.xml 2009-03-08
22:23:49 UTC (rev 1821)
+++
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/beans.xml 2009-03-08
22:33:13 UTC (rev 1822)
@@ -1,8 +0,0 @@
-<Beans xmlns="urn:java:ee"
- xmlns:test="urn:java:org.jboss.jsr299.tck.tests.context.dependent">
- <Deploy>
- <Standard />
- <Production />
- <test:AnotherDeploymentType />
- </Deploy>
-</Beans>
Property changes on:
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client
___________________________________________________________________
Name: svn:ignore
+ .faces-config.xml.jsfdia
Copied:
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/cloud.jsf
(from rev 1818,
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/cloud.jsf)
===================================================================
---
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/cloud.jsf
(rev 0)
+++
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/cloud.jsf 2009-03-08
22:33:13 UTC (rev 1822)
@@ -0,0 +1,22 @@
+<?xml version="1.0"?>
+<jsp:root
xmlns:jsp="http://java.sun.com/JSP/Page"
+
xmlns:h="http://java.sun.com/jsf/html"
+
xmlns:f="http://java.sun.com/jsf/core"
+
xmlns:s="http://jboss.com/products/seam/taglib"
+
xmlns="http://www.w3.org/1999/xhtml"
+ version="2.0">
+ <jsp:output doctype-root-element="html"
+ doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN"
+
doctype-system="http://www.w3c.org/TR/xhtml1/DTD/xhtml1-transitional...
+ <jsp:directive.page contentType="text/html"/>
+ <html>
+ <head>
+ </head>
+ <body>
+ <f:view>
+ <h:outputText value="#{cloud.name}" />
+ </f:view>
+ </body>
+ </html>
+</jsp:root>
+
Property changes on:
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/cloud.jsf
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Copied:
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/clouds.jsf
(from rev 1818,
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/clouds.jsf)
===================================================================
---
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/clouds.jsf
(rev 0)
+++
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/clouds.jsf 2009-03-08
22:33:13 UTC (rev 1822)
@@ -0,0 +1,23 @@
+<?xml version="1.0"?>
+<jsp:root
xmlns:jsp="http://java.sun.com/JSP/Page"
+
xmlns:h="http://java.sun.com/jsf/html"
+
xmlns:f="http://java.sun.com/jsf/core"
+
xmlns:s="http://jboss.com/products/seam/taglib"
+
xmlns="http://www.w3.org/1999/xhtml"
+ version="2.0">
+ <jsp:output doctype-root-element="html"
+ doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN"
+
doctype-system="http://www.w3c.org/TR/xhtml1/DTD/xhtml1-transitional...
+ <jsp:directive.page contentType="text/html"/>
+ <html>
+ <head>
+ </head>
+ <body>
+ <f:view>
+ <h:outputText value="#{cloud.name}" />
+ <h:outputText value="#{cloudController.beginConversation}" />
+ </f:view>
+ </body>
+ </html>
+</jsp:root>
+
Property changes on:
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/clouds.jsf
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added:
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/faces-config.xml
===================================================================
---
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/faces-config.xml
(rev 0)
+++
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/faces-config.xml 2009-03-08
22:33:13 UTC (rev 1822)
@@ -0,0 +1,28 @@
+<?xml version="1.0"?>
+<faces-config version="1.2"
+
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://java.sun.com/xml/ns/javaee/web-facesconfig_1_2.xsd">
+
+ <lifecycle>
+
<phase-listener>org.jboss.jsr299.tck.tests.context.conversation.client.ConversationTestPhaseListener</phase-listener>
+ </lifecycle>
+
+ <navigation-rule>
+ <from-view-id>/storm.jspx</from-view-id>
+ <navigation-case>
+ <from-outcome>thunder</from-outcome>
+ <to-view-id>/thunder.jspx</to-view-id>
+ </navigation-case>
+ </navigation-rule>
+
+ <navigation-rule>
+ <from-view-id>/storm.jspx</from-view-id>
+ <navigation-case>
+ <from-outcome>lightening</from-outcome>
+ <to-view-id>/lightening.jspx</to-view-id>
+ <redirect/>
+ </navigation-case>
+ </navigation-rule>
+
+</faces-config>
Property changes on:
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/faces-config.xml
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Copied:
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/home.jsf
(from rev 1818,
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/home.jsf)
===================================================================
---
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/home.jsf
(rev 0)
+++
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/home.jsf 2009-03-08
22:33:13 UTC (rev 1822)
@@ -0,0 +1,20 @@
+<?xml version="1.0"?>
+<jsp:root
xmlns:jsp="http://java.sun.com/JSP/Page"
+
xmlns:h="http://java.sun.com/jsf/html"
+
xmlns:f="http://java.sun.com/jsf/core"
+
xmlns:s="http://jboss.com/products/seam/taglib"
+
xmlns="http://www.w3.org/1999/xhtml"
+ version="2.0">
+ <jsp:output doctype-root-element="html"
+ doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN"
+
doctype-system="http://www.w3c.org/TR/xhtml1/DTD/xhtml1-transitional...
+ <jsp:directive.page contentType="text/html"/>
+ <html>
+ <head>
+ </head>
+ <body>
+
+ </body>
+ </html>
+</jsp:root>
+
Property changes on:
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/home.jsf
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added:
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/lightening.jsf
===================================================================
---
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/lightening.jsf
(rev 0)
+++
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/lightening.jsf 2009-03-08
22:33:13 UTC (rev 1822)
@@ -0,0 +1,23 @@
+<?xml version="1.0"?>
+<jsp:root
xmlns:jsp="http://java.sun.com/JSP/Page"
+
xmlns:h="http://java.sun.com/jsf/html"
+
xmlns:f="http://java.sun.com/jsf/core"
+
xmlns:s="http://jboss.com/products/seam/taglib"
+
xmlns="http://www.w3.org/1999/xhtml" version="2.0">
+ <jsp:output doctype-root-element="html"
+ doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN"
+
doctype-system="http://www.w3c.org/TR/xhtml1/DTD/xhtml1-transitional...
/>
+ <jsp:directive.page contentType="text/html" />
+ <html>
+ <head>
+ </head>
+ <body>
+ <f:view>
+ <h:form>
+ <h:inputText value="#{storm.strength}" id="stormStrength"
/>
+ </h:form>
+ </f:view>
+ </body>
+ </html>
+</jsp:root>
+
Property changes on:
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/lightening.jsf
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added:
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/rain.jsf
===================================================================
---
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/rain.jsf
(rev 0)
+++
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/rain.jsf 2009-03-08
22:33:13 UTC (rev 1822)
@@ -0,0 +1,23 @@
+<?xml version="1.0"?>
+<jsp:root
xmlns:jsp="http://java.sun.com/JSP/Page"
+
xmlns:h="http://java.sun.com/jsf/html"
+
xmlns:f="http://java.sun.com/jsf/core"
+
xmlns:s="http://jboss.com/products/seam/taglib"
+
xmlns="http://www.w3.org/1999/xhtml"
+ version="2.0">
+ <jsp:output doctype-root-element="html"
+ doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN"
+
doctype-system="http://www.w3c.org/TR/xhtml1/DTD/xhtml1-transitional...
+ <jsp:directive.page contentType="text/html"/>
+ <html>
+ <head>
+ </head>
+ <body>
+ <f:view>
+ <h:outputText value="#{cloud.rain}" />
+ <h:outputText value="#{cloudController.beginConversation}" />
+ </f:view>
+ </body>
+ </html>
+</jsp:root>
+
Property changes on:
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/rain.jsf
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added:
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/storm.jsf
===================================================================
---
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/storm.jsf
(rev 0)
+++
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/storm.jsf 2009-03-08
22:33:13 UTC (rev 1822)
@@ -0,0 +1,26 @@
+<?xml version="1.0"?>
+<jsp:root
xmlns:jsp="http://java.sun.com/JSP/Page"
+
xmlns:h="http://java.sun.com/jsf/html"
+
xmlns:f="http://java.sun.com/jsf/core"
+
xmlns:s="http://jboss.com/products/seam/taglib"
+
xmlns="http://www.w3.org/1999/xhtml"
+ version="2.0">
+ <jsp:output doctype-root-element="html"
+ doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN"
+
doctype-system="http://www.w3c.org/TR/xhtml1/DTD/xhtml1-transitional...
+ <jsp:directive.page contentType="text/html"/>
+ <html>
+ <head>
+ </head>
+ <body>
+ <f:view>
+ <h:form id="form">
+ <h:inputText value="#{storm.strength}" id="stormStrength"
/>
+ <h:commandButton action="#{storm.beginConversation}"
value="Thunder" id="beginConversationButton"/>
+ <h:commandButton action="#{storm.thunder}"
value="Thunder" id="thunderButton"/>
+ <h:commandButton action="#{storm.lightening}"
value="Thunder" id="lighteningButton"/>
+ </h:form>
+ </f:view>
+ </body>
+ </html>
+</jsp:root>
\ No newline at end of file
Property changes on:
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/storm.jsf
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added:
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/thunder.jsf
===================================================================
---
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/thunder.jsf
(rev 0)
+++
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/thunder.jsf 2009-03-08
22:33:13 UTC (rev 1822)
@@ -0,0 +1,23 @@
+<?xml version="1.0"?>
+<jsp:root
xmlns:jsp="http://java.sun.com/JSP/Page"
+
xmlns:h="http://java.sun.com/jsf/html"
+
xmlns:f="http://java.sun.com/jsf/core"
+
xmlns:s="http://jboss.com/products/seam/taglib"
+
xmlns="http://www.w3.org/1999/xhtml" version="2.0">
+ <jsp:output doctype-root-element="html"
+ doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN"
+
doctype-system="http://www.w3c.org/TR/xhtml1/DTD/xhtml1-transitional...
/>
+ <jsp:directive.page contentType="text/html" />
+ <html>
+ <head>
+ </head>
+ <body>
+ <f:view>
+ <h:form>
+ <h:inputText value="#{storm.strength}" id="stormStrength"
/>
+ </h:form>
+ </f:view>
+ </body>
+ </html>
+</jsp:root>
+
Property changes on:
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/thunder.jsf
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Copied:
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/web.xml
(from rev 1818,
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/web.xml)
===================================================================
---
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/web.xml
(rev 0)
+++
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/web.xml 2009-03-08
22:33:13 UTC (rev 1822)
@@ -0,0 +1,42 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<web-app version="2.5"
+
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://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
+
+ <display-name>JSR-299 TCK</display-name>
+
+ <!-- JSF -->
+
+ <servlet>
+ <servlet-name>Faces Servlet</servlet-name>
+ <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
+ <load-on-startup>1</load-on-startup>
+ </servlet>
+
+ <servlet-mapping>
+ <servlet-name>Faces Servlet</servlet-name>
+ <url-pattern>*.jsf</url-pattern>
+ </servlet-mapping>
+
+ <context-param>
+ <param-name>javax.faces.DEFAULT_SUFFIX</param-name>
+ <param-value>.jspx</param-value>
+ </context-param>
+
+ <servlet>
+ <servlet-name>Conversation Status Servlet</servlet-name>
+
<servlet-class>org.jboss.jsr299.tck.tests.context.conversation.client.ConversationStatusServlet</servlet-class>
+ </servlet>
+
+ <servlet-mapping>
+ <servlet-name>Conversation Status Servlet</servlet-name>
+ <url-pattern>/conversation-status</url-pattern>
+ </servlet-mapping>
+
+ <session-config>
+ <session-timeout>10</session-timeout>
+ </session-config>
+
+</web-app>
Property changes on:
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/client/web.xml
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Deleted:
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/cloud.jsf
===================================================================
---
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/cloud.jsf 2009-03-08
22:23:49 UTC (rev 1821)
+++
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/cloud.jsf 2009-03-08
22:33:13 UTC (rev 1822)
@@ -1,22 +0,0 @@
-<?xml version="1.0"?>
-<jsp:root
xmlns:jsp="http://java.sun.com/JSP/Page"
-
xmlns:h="http://java.sun.com/jsf/html"
-
xmlns:f="http://java.sun.com/jsf/core"
-
xmlns:s="http://jboss.com/products/seam/taglib"
-
xmlns="http://www.w3.org/1999/xhtml"
- version="2.0">
- <jsp:output doctype-root-element="html"
- doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN"
-
doctype-system="http://www.w3c.org/TR/xhtml1/DTD/xhtml1-transitional...
- <jsp:directive.page contentType="text/html"/>
- <html>
- <head>
- </head>
- <body>
- <f:view>
- <h:outputText value="#{cloud.name}" />
- </f:view>
- </body>
- </html>
-</jsp:root>
-
Deleted:
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/clouds.jsf
===================================================================
---
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/clouds.jsf 2009-03-08
22:23:49 UTC (rev 1821)
+++
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/clouds.jsf 2009-03-08
22:33:13 UTC (rev 1822)
@@ -1,23 +0,0 @@
-<?xml version="1.0"?>
-<jsp:root
xmlns:jsp="http://java.sun.com/JSP/Page"
-
xmlns:h="http://java.sun.com/jsf/html"
-
xmlns:f="http://java.sun.com/jsf/core"
-
xmlns:s="http://jboss.com/products/seam/taglib"
-
xmlns="http://www.w3.org/1999/xhtml"
- version="2.0">
- <jsp:output doctype-root-element="html"
- doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN"
-
doctype-system="http://www.w3c.org/TR/xhtml1/DTD/xhtml1-transitional...
- <jsp:directive.page contentType="text/html"/>
- <html>
- <head>
- </head>
- <body>
- <f:view>
- <h:outputText value="#{cloud.name}" />
- <h:outputText value="#{cloudController.beginConversation}" />
- </f:view>
- </body>
- </html>
-</jsp:root>
-
Deleted:
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/home.jsf
===================================================================
---
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/home.jsf 2009-03-08
22:23:49 UTC (rev 1821)
+++
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/home.jsf 2009-03-08
22:33:13 UTC (rev 1822)
@@ -1,20 +0,0 @@
-<?xml version="1.0"?>
-<jsp:root
xmlns:jsp="http://java.sun.com/JSP/Page"
-
xmlns:h="http://java.sun.com/jsf/html"
-
xmlns:f="http://java.sun.com/jsf/core"
-
xmlns:s="http://jboss.com/products/seam/taglib"
-
xmlns="http://www.w3.org/1999/xhtml"
- version="2.0">
- <jsp:output doctype-root-element="html"
- doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN"
-
doctype-system="http://www.w3c.org/TR/xhtml1/DTD/xhtml1-transitional...
- <jsp:directive.page contentType="text/html"/>
- <html>
- <head>
- </head>
- <body>
-
- </body>
- </html>
-</jsp:root>
-
Deleted:
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/web.xml
===================================================================
---
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/web.xml 2009-03-08
22:23:49 UTC (rev 1821)
+++
tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/context/conversation/web.xml 2009-03-08
22:33:13 UTC (rev 1822)
@@ -1,42 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<web-app version="2.5"
-
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://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
-
- <display-name>JSR-299 TCK</display-name>
-
- <!-- JSF -->
-
- <servlet>
- <servlet-name>Faces Servlet</servlet-name>
- <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
- <load-on-startup>1</load-on-startup>
- </servlet>
-
- <servlet-mapping>
- <servlet-name>Faces Servlet</servlet-name>
- <url-pattern>*.jsf</url-pattern>
- </servlet-mapping>
-
- <context-param>
- <param-name>javax.faces.DEFAULT_SUFFIX</param-name>
- <param-value>.jspx</param-value>
- </context-param>
-
- <servlet>
- <servlet-name>Conversation Status Servlet</servlet-name>
-
<servlet-class>org.jboss.jsr299.tck.tests.context.conversation.ConversationStatusServlet</servlet-class>
- </servlet>
-
- <servlet-mapping>
- <servlet-name>Conversation Status Servlet</servlet-name>
- <url-pattern>/conversation-status</url-pattern>
- </servlet-mapping>
-
- <session-config>
- <session-timeout>10</session-timeout>
- </session-config>
-
-</web-app>
Modified: tck/trunk/impl/src/main/resources/tck-audit.xml
===================================================================
--- tck/trunk/impl/src/main/resources/tck-audit.xml 2009-03-08 22:23:49 UTC (rev 1821)
+++ tck/trunk/impl/src/main/resources/tck-audit.xml 2009-03-08 22:33:13 UTC (rev 1822)
@@ -5045,8 +5045,9 @@
<note>Not required</note>
</assertion>
- <assertion id="u">
+ <assertion id="u" testable="false">
<text>The container ensures that a long-running conversation may be
associated with at most one request at a time, by blocking or rejecting concurrent
requests</text>
+ <note>Cannot test as their as what happens is not well defined</note>
</assertion>
</section>
@@ -5070,7 +5071,7 @@
</assertion>
</section>
- <section id="9" title="XML based metadata">
+ <!-- <section id="9" title="XML based metadata">
<assertion id="a">
<text>XML-based bean declarations define additional beans?they do not
redefine or disable any bean that was declared via annotations</text>
</assertion>
@@ -5671,6 +5672,6 @@
<section id="9.6.2" title="Child elements of a producer method
declaration">
- </section>
+ </section>-->
</specification>
Modified: tck/trunk/pom.xml
===================================================================
--- tck/trunk/pom.xml 2009-03-08 22:23:49 UTC (rev 1821)
+++ tck/trunk/pom.xml 2009-03-08 22:33:13 UTC (rev 1822)
@@ -135,6 +135,11 @@
<artifactId>commons-httpclient</artifactId>
<version>3.1</version>
</dependency>
+ <dependency>
+ <groupId>net.sourceforge.htmlunit</groupId>
+ <artifactId>htmlunit</artifactId>
+ <version>2.4</version>
+ </dependency>
</dependencies>
</dependencyManagement>