Buggy code:
public FormTester newFormTester ( String path ) { } public FormTester newFormTester ( String path , boolean fillBlankString ) { } public final Panel startPanel ( final TestPanelSource testPanelSource ) { } public final < C extends Panel > Panel startPanel ( final Class < C > panelClass ) { } public void startComponent ( Component component ) { } private RuntimeException convertoUnexpect ( Exception e ) { } public Component getComponentFromLastRenderedPage ( String path ) { } public Result hasLabel ( String path , String expectedLabelText ) { } public < C extends Component > Result isComponent ( String path , Class < C > expectedComponentClass ) { } public Result isVisible ( String path ) { } public Result isInvisible ( String path ) { } public Result isEnabled ( String path ) { } public Result isDisabled ( String path ) { } public Result isRequired ( String path ) { } public Result isRequired ( FormComponent < ? > component ) { } public Result ifContains ( String pattern ) { } public void assertListView ( String path , List < ? > expectedList ) { } public void clickLink ( String path ) { } public void clickLink ( String path , boolean isAjax ) { } public void submitForm ( Form < ? > form ) { } public void submitForm ( String path ) { } private void transform ( Url url ) { } public < C extends Page > Result isRenderedPage ( Class < C > expectedRenderedPageClass ) { } public void assertResultPage ( final Class < ? > pageClass , final String filename ) throws Exception { } public Result isResultPage ( final String expectedDocument ) throws Exception { } public Result hasNoErrorMessage ( ) { } public Result hasNoInfoMessage ( ) { } public List < Serializable > getMessages ( final int level ) { } public void dumpPage ( ) { } public void debugComponentTrees ( ) { } public void debugComponentTrees ( String filter ) { } public Result isComponentOnAjaxResponse ( Component component ) { } public void executeAjaxEvent ( String componentPath , String event ) { } public void executeAllTimerBehaviors ( MarkupContainer container ) { } public void executeAjaxEvent ( final Component component , final String event ) { } public TagTester getTagByWicketId ( String wicketId ) { } public List < TagTester > getTagsByWicketId ( String wicketId ) { } public TagTester getTagById ( String id ) { } private void submitAjaxFormSubmitBehavior ( final Component component , AjaxFormSubmitBehavior behavior ) { } private void serializeFormToRequest ( final Form < ? > form ) { } public String getContentTypeFromResponseHeader ( ) { } public int getContentLengthFromResponseHeader ( ) { } public String getLastModifiedFromResponseHeader ( ) { } public String getContentDispositionFromResponseHeader ( ) { } public void applyRequest ( ) { } private Result isTrue ( String message , boolean condition ) { } private Result isFalse ( String message , boolean condition ) { } protected final Result isEqual ( Object expected , Object actual ) { } private void notNull ( String message , Object object ) { } private Result isNull ( String message , Object object ) { } private void checkUsability ( final Component component ) { } protected final void fail ( String message ) { } public RequestCycle getRequestCycle ( ) { } public MockHttpServletResponse getResponse ( ) { } public MockHttpServletRequest getLastRequest ( ) { } public boolean isExposeExceptions ( ) { } public void setExposeExceptions ( boolean exposeExceptions ) { } public boolean isUseRequestUrlAsBase ( ) { } public void setUseRequestUrlAsBase ( boolean setBaseUrl ) { } public void executeUrl ( String _url ) { } private class LastPageRecordingPageRendererProvider implements IPageRendererProvider { private final IPageRendererProvider delegate ; public LastPageRecordingPageRendererProvider ( IPageRendererProvider delegate ) { } public PageRenderer get ( RenderPageRequestHandler handler ) { } } private class TestExceptionMapper implements IExceptionMapper { private final IExceptionMapper delegate ; public TestExceptionMapper ( IExceptionMapper delegate ) { } public IRequestHandler map ( Exception e ) { } } private class TestRequestCycleProvider implements IRequestCycleProvider { private final IRequestCycleProvider delegate ; public TestRequestCycleProvider ( IRequestCycleProvider delegate ) { } public RequestCycle get ( RequestCycleContext context ) { } } private class TestRequestMapper implements IRequestMapper { private final IRequestMapper delegate ; public TestRequestMapper ( IRequestMapper delegate ) { } public int getCompatibilityScore ( Request request ) { } public Url mapHandler ( IRequestHandler requestHandler ) { } public IRequestHandler mapRequest ( Request request ) { } } private class TestSessionStore extends MockSessionStore { @ Override public void invalidate ( Request request ) { } } private class TestSessionStoreProvider implements IProvider < ISessionStore > { public ISessionStore get ( ) { } } private static class TestPageManagerProvider implements IPageManagerProvider { public IPageManager get ( IPageManagerContext pageManagerContext ) { } } private class TestFilterConfig implements FilterConfig { private final Map < String , String > initParameters = new HashMap < String , String > ( ) ; public TestFilterConfig ( ) { } public String getFilterName ( ) { } public ServletContext getServletContext ( ) { } public String getInitParameter ( String s ) { } public Enumeration < String > getInitParameterNames ( ) { } } private static class WicketTesterServletWebResponse extends ServletWebResponse implements IMetaDataBufferingWebResponse { private List < Cookie > cookies = new ArrayList < Cookie > ( ) ; public WicketTesterServletWebResponse ( ServletWebRequest request , MockHttpServletResponse response ) { } @ Override public void addCookie ( Cookie cookie ) { } @ Override public void clearCookie ( Cookie cookie ) { } public void writeMetaData ( WebResponse webResponse ) { } @ Override public void sendRedirect ( String url ) { super . sendRedirect ( url ) ; try { <START_BUG> getHttpServletResponse ( ) . sendRedirect ( url ) ; <END_BUG> } catch ( IOException e ) { throw new RuntimeException ( e ) ; } } } }

Fix:
getContainerResponse ( ) . sendRedirect ( url ) ;