According to the code it returns a DummyHomePage which is most definitely a Page. Are you supplying WicketTester with an Application of your own? What wicket version are you running?
Maurice On Sun, May 25, 2008 at 10:00 PM, Izak Wessels <[EMAIL PROTECTED]> wrote: > > Could somebody please explain to me > wicketTester.getApplication().getHomePage() returns a class that is an > instance of my main Application class? > > The reason that I ask, is that I have a test case that ends up calling the > constructor of the BookmarkablePageRequestTarget and it tries to check if > Page.class is assignable from pageClass that gets passed in, and since > wicketTester.getApplication().getHomePage() returns an Application class, > rather than a Page class, it throws an exception. > > java.lang.IllegalArgumentException: Argument pageClass must be an instance > of org.apache.wicket.Page > at > org.apache.wicket.request.target.component.BookmarkablePageRequestTarget.<init>(BookmarkablePageRequestTarget.java:107) > > > Any help would be much appreciated, > > -- izak > > > -- > View this message in context: > http://www.nabble.com/WicketTester-%3A-getHomePage-returns-Application-tp17461747p17461747.html > Sent from the Wicket - User mailing list archive at Nabble.com. > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
