protected function _init() { parent::_init(); $this->_timestamp = time(); $this->_tmp_dir = 'li3_fs_' . $this->_timestamp . '_ftp_test'; $this->_adapter = Locations::get('li3-fs-ftp-test'); }
protected function _init() { parent::_init(); $this->_timestamp = time(); $this->_tmp_dir = sys_get_temp_dir() . '/li3_fs_' . $this->_timestamp . '_test-2'; Locations::add('test-2', array('adapter' => 'Filesystem', 'url' => 'http://example.com/tmp/', 'location' => $this->_tmp_dir)); $this->_adapter = Locations::get('test'); }
public function testGetting() { $this->assertTrue(is_array(Locations::get())); $this->assertNull(Locations::get('test2')); $this->assertTrue(is_array(Locations::get('test', array('config' => true)))); $this->assertNull(Locations::get('test', array('autoCreate' => false))); $this->assertNotEmpty(Locations::get('test')); }