com.mockobjects.helpers
Class TagTestHelper
public class TagTestHelper
Sets up mock tag objects in a common configuration.
MockHttpServletRequest, MockServletContext and MockHttpSession are attached to MockPageContext
com.mockobjects.servlet.MockPageContext.setRequest();, com.mockobjects.servlet.MockPageContext.setServletContext();, com.mockobjects.servlet.MockPageContext.setSession();
TagTestHelper
public TagTestHelper(Tag testSubject)
testSubject - The Tag to be tested
assertDoAfterBody
public void assertDoAfterBody(int expectedValue)
throws JspException Assert that the return value of doAfterBody is equal to an expectedValue
expectedValue - value to check against doAfterBody
assertDoEndTag
public void assertDoEndTag(int expectedValue)
throws JspException Assert that the return value of doEndTag is equal to an expectedValue
expectedValue - value to check against doEndTag
assertDoStartTag
public void assertDoStartTag(int expectedValue)
throws JspException Assert that the return value of doStartTag is equal to an expectedValue
expectedValue - value to check against doStartTag
getOutWriter
public MockJspWriter getOutWriter()
- The writer use when making calls to PageContext.getOut
testDoInitBody
public void testDoInitBody()
throws JspException Invoke doInitBody on the test subject
Copyright © 2002 Mock Objects. All Rights Reserved.