Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.jboss.seam.mock
Class SeamTest

    java.lang.Object
      org.jboss.seam.mock.SeamTest

    public class SeamTest

extends Object

Superclass for TestNG integration tests for JSF/Seam applications.

Version:
  $Revision: 4253 $
Author:
  Gavin King, Thomas Heute

Nested Class Summary
`class` | `SeamTest.FacesRequest`
`class` | `SeamTest.NonFacesRequest`
`class` | `SeamTest.Script` Deprecated. use FacesRequest or NonFacesRequest

Constructor Summary
`SeamTest()`

Method Summary
`void` | `begin()`
`void` | `cleanup()`
`protected AbstractSeamPhaseListener` | `createPhaseListener()` Create a SeamPhaseListener by default.
`void` | `end()`
`protected Object` | `getField(Object object, String fieldName)` Get the value of an object field, by reflection.
`protected Map<String,String[]>` | `getHeaders()`
`protected InitialContext` | `getInitialContext()`
`protected Object` | `getInstance(Class clazz)` Helper method for resolving components in the test script.
`protected Object` | `getInstance(String name)` Helper method for resolving components in the test script.
`protected Map<String,String[]>` | `getParameters()`
`protected javax.servlet.http.HttpSession` | `getSession()`
`protected UserTransaction` | `getUserTransaction()`
`void` | `init()`
`void` | `initServletContext(Map initParams)` Override to set up any servlet context attributes.
`protected boolean` | `isLongRunningConversation()` Is there a long running conversation associated with the current request?
`protected boolean` | `isSessionInvalid()`
`Object` | `lookup(String name)` Search in all contexts
`protected void` | `setField(Object object, String fieldName, Object value)` Set the value of an object field, by reflection.
`protected void` | `setPageParameter(String name, Object value)`
`protected void` | `setParameter(String name, String value)`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### SeamTest

    public SeamTest()

Method Detail

### setParameter

    protected void setParameter(String name,
                                String value)

### setPageParameter

    protected void setPageParameter(String name,
                                    Object value)

### getParameters

    protected Map<String,String[]> getParameters()

### getHeaders

    protected Map<String,String[]> getHeaders()

### getSession

    protected javax.servlet.http.HttpSession getSession()

### isSessionInvalid

    protected boolean isSessionInvalid()

### getInstance

    protected Object getInstance(Class clazz)

  Helper method for resolving components in the test script.

### getInstance

    protected Object getInstance(String name)

  Helper method for resolving components in the test script.

### isLongRunningConversation

    protected boolean isLongRunningConversation()

  Is there a long running conversation associated with the current request?

### lookup

    public Object lookup(String name)

  Search in all contexts

### begin

    public void begin()

### end

    public void end()

### createPhaseListener

    protected AbstractSeamPhaseListener createPhaseListener()

  Create a SeamPhaseListener by default. Override to use one of the other standard Seam phase listeners.

### init

    public void init()
              throws Exception

  Throws:
    `Exception`

### cleanup

    public void cleanup()
                 throws Exception

  Throws:
    `Exception`

### initServletContext

    public void initServletContext(Map initParams)

  Override to set up any servlet context attributes.

### getInitialContext

    protected InitialContext getInitialContext()
                                        throws NamingException

  Throws:
    `NamingException`

### getUserTransaction

    protected UserTransaction getUserTransaction()
                                          throws NamingException

  Throws:
    `NamingException`

### getField

    protected Object getField(Object object,
                              String fieldName)

  Get the value of an object field, by reflection.

### setField

    protected void setField(Object object,
                            String fieldName,
                            Object value)

  Set the value of an object field, by reflection.

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD