public function splAutoloadRegister($suppress = true, $fallback = false) { $this->suppress = $suppress; $this->fallback = $fallback; if ($this->fallback) { spl_autoload_register($this, true, false); } else { spl_autoload_register($this, true, true); } return $this; }
public function testFallback() { $a = new Autoloader(); $a->splAutoloadRegister(false, true); $this->assertInstanceOf('Pop\\Loader\\Autoloader', $a); }