I'm running some unit-tests using PHPUnit, and hack my application pretty hard in those tests (no other way, old code-base). Some parts of the code-base use
You can simply use:
$ctrl = new CController('whatever you need for the id')
and use its methods. Be careful, construct method sets
id only. You didn't provide too much code, so this is a general idea. Look inside
createUrl() method and check if it should work.
I used this technique to render pages (and use their contents) under console enviroment.