Package

net.liftweb

mocks

Permalink

package mocks

Visibility
  1. Public
  2. All

Type Members

  1. class DoNothingFilterChain extends FilterChain with Logger

    Permalink

    A FilterChain that does nothing.

  2. class MockFilterConfig extends FilterConfig

    Permalink

    A Mock FilterConfig.

    A Mock FilterConfig. Construct with a MockServletContext and pass into LiftFilter.init

  3. class MockHttpServletRequest extends HttpServletRequest

    Permalink

    A Mock ServletRequest.

    A Mock ServletRequest. Change its state to create the request you are interested in. At the very least, you will need to change method and path.

    There are several things that aren't supported:

    • getRequestDispatcher - returns null always
    • getRequestedSessionId - always returns null. The related isRequestedSessionId... methods similarly all return false
    • getRealPath - simply returns the input string
  4. class MockHttpServletResponse extends HttpServletResponse

    Permalink

    A Mock HttpServletResponse.

    A Mock HttpServletResponse. Take a peek at it's writer or outputStream to see what lift has written in response to your request

  5. class MockHttpSession extends HttpSession

    Permalink

    A Mock HttpSession implementation.

  6. class MockServletContext extends ServletContext

    Permalink

    A Mock ServletContext.

    A Mock ServletContext. LiftFilter expects a ServletContext inside a FilterConfig

  7. class MockServletInputStream extends ServletInputStream

    Permalink

    A Mock ServletInputStream.

    A Mock ServletInputStream. Pass in any ol InputStream like a ByteArrayInputStream.

  8. class MockServletOutputStream extends ServletOutputStream

    Permalink

    A Mock ServletOutputStream.

    A Mock ServletOutputStream. Pass in any ol' OutputStream like a ByteArrayOuputStream.

Ungrouped