protected function setUp() { $this->configuration = new Configuration('localhost'); $this->auth = new Password(TEST_USER, TEST_PASSWORD); $this->session = new Session($this->configuration, $this->auth); $this->sftp = $this->session->getSftp(); $this->createFixtures(); }
/** * {@inheritdoc} */ public function download($local, $remote) { $this->checkConnection(); if (!$this->session->getSftp()->receive($remote, $local)) { throw new \RuntimeException('Can not download file.'); } }