public function invoke($method, array $arguments = array()) { $method = self::mapMethod($method); if ($method === 'dir_rewinddir' && isset($this->{$method}) === true) { $this->resetCalls('dir_readdir'); } return isset($this->{$method}) === false ? null : parent::invoke($method, $arguments); }
public function test__set() { $this->if($adapter = new testedClass())->and($adapter->md5 = $closure = function () { })->then->object($adapter->md5->getClosure())->isIdenticalTo($closure)->if($adapter->md5 = $return = uniqid())->then->object($adapter->md5)->isInstanceOf('mageekguy\\atoum\\test\\adapter\\invoker')->object($adapter->MD5)->isInstanceOf('mageekguy\\atoum\\test\\adapter\\invoker')->string($adapter->invoke('md5'))->isEqualTo($return)->string($adapter->invoke('MD5'))->isEqualTo($return)->if($adapter->MD5 = $return = uniqid())->then->object($adapter->md5)->isInstanceOf('mageekguy\\atoum\\test\\adapter\\invoker')->object($adapter->MD5)->isInstanceOf('mageekguy\\atoum\\test\\adapter\\invoker')->string($adapter->invoke('md5'))->isEqualTo($return)->string($adapter->invoke('MD5'))->isEqualTo($return); }
public function invoke($method, array $arguments = array()) { $this->checkMethod($method); if (isset($this->{$method}) === false) { throw new exceptions\logic('Method ' . $method . '() is not under control'); } return parent::invoke($method, $arguments); }