/** * @return \ReflectionClass */ protected function getReflector() { return $this->cli->getScript($this->name); }
/** * @return \Nano\Cli\Script * @param $name */ protected function getScript($name) { $result = $this->cli->getScript($name); return $result->newInstance($name, $this->cli); }
public function testGetScriptShouldReturnScriptIfExists() { Nano::setApplication(null); self::assertEquals(0, $this->cli->run(array())); self::assertInstanceOf('ReflectionClass', $this->cli->getScript('test-script')); }