Right now it's pretty hard to test In-Portal's code, because each class:
gets reference to kApplication class by calling $this->Application = kApplication::Instance();
then retrieves current database connection by calling $this->Conn = $this->Application->GetADODBConnection();
then if that class needs another class, then it does $another_object = $this->Application->recallObject('some-alias-name');
With all of that in place it's pretty hard to mock anything to test any individual class in isolation. All is tied to kApplication class, because it implements Facade pattern and allows any other class to access any part of a system.
...
More reading: http://blog.astrumfutura.com/2011/10/zend-framework-2-0-dependency-injection-part-2/