Esempio n. 1
0
 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');
 }
Esempio n. 2
0
 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');
 }
Esempio n. 3
0
 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'));
 }