Sorry for bothering you guys before doing enough research myself. I've been digging into this for a while, and found that the basic documentation tells me how to test a page with an activation context. The problem now is that the docs for that is outdated, the ComponentInvocation seems to have turned into an interface. Does anyone have a new "best practice" for passing an activation context to a page under test, since the documentation is outdated?
I also figured out the solution to the context asset problem. After checking out the PageTester source, I found that System.getProperty("user.dir") got me what I wanted, and enabled me to specify the correct web context root. Inge On Fri, Feb 27, 2009 at 11:55 AM, Inge Solvoll <inge.tapes...@gmail.com>wrote: > I've managed to mock up all my services in a separate Module class, and got > the PageTester working. But there are a few things that I still haven't > found a solution for: > > 1. context-assets don't work. My project structure is like this: > > <Project>/src: all java and tml files > <Project>/web/WEB-INF/classes: all class and tml files > <Project>/web/WEB-INF/classes: all class and tml files > <Project>/web: Web application root > > I'm getting an error when a page tries to do > "asset:context:/img/banner.gif". It works in the real application. > > > > 2. Activation context doesn't work > > The page url "item/edit" is a valid url, while "item/edit/1" is considered > a bad url, no page exists with the name "item/edit/1". It works in the real > application. I'm using ActivationContext annotation, I'll try with > onActivate and onPassivate instead. >