public function setUp() { $this->container = new Ioc(); Ioc::register('NullObject', function () { return new NullObject(); }); }
/** * Constructor calls parent constructor and resolves * Dependencies from the Ioc container */ public function __construct() { parent::__construct(); $this->request = $this->resolve('Request'); $this->view = $this->resolve('View'); $this->input = $this->resolve('Input'); $this->input->createFromGlobals(); }