class
WebObject[B <: WebObjectBody] extends AnyRef
Instance Constructors
-
new
WebObject(request: MockHttpServletRequest, response: MockHttpServletResponse, modelAndView: Option[ModelAndView], bodyOption: Option[B])
Type Members
-
class
Model extends AnyRef
Value Members
-
def
!: B
-
final
def
!=(arg0: AnyRef): Boolean
-
final
def
!=(arg0: Any): Boolean
-
final
def
##(): Int
-
final
def
==(arg0: AnyRef): Boolean
-
final
def
==(arg0: Any): Boolean
-
final
def
asInstanceOf[T0]: T0
-
def
body: B
-
val
bodyOption: Option[B]
-
def
clone(): AnyRef
-
final
def
eq(arg0: AnyRef): Boolean
-
def
equals(arg0: Any): Boolean
-
def
finalize(): Unit
-
final
def
getClass(): java.lang.Class[_]
-
def
hashCode(): Int
-
final
def
isInstanceOf[T0]: Boolean
-
def
model: Model
-
val
modelAndView: Option[ModelAndView]
-
def
modelOption: Option[Model]
-
final
def
ne(arg0: AnyRef): Boolean
-
final
def
notify(): Unit
-
final
def
notifyAll(): Unit
-
val
request: MockHttpServletRequest
-
val
response: MockHttpServletResponse
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
-
def
toString(): String
-
final
def
wait(): Unit
-
final
def
wait(arg0: Long, arg1: Int): Unit
-
final
def
wait(arg0: Long): Unit
Inherited from AnyRef
Inherited from Any
Represents processed and pre-chewed HttpServletResponse so that you can write meaningful code in your examples. The instances of {{WebObject}} carry the originating {{request}}, the matching {{response}}, together with extracted {{modelAndView}} and a pre-processed {{body}}. The methods {{<<}}, {{>>}} and {{>>!}} manipulate the {{body}}, allowing you to get or set the value of some HTML element, execute arbitrary JavaScript, examine the PDF, ... (depending on what payload processing traits you mixin to your test). Finally, the {{model}} and {{modelOption}} give you access to the model elements of the {{ModelAndView}} returned from the controller processing.