Blame view

sources/apps/files_sharing/tests/helper.php 1.21 KB
03e52840d   Kload   Init
1
  <?php
03e52840d   Kload   Init
2
  /**
d1bafeea1   Kload   [fix] Upgrade to ...
3
   * ownCloud
03e52840d   Kload   Init
4
   *
f7d878ff1   kload   [enh] Update to 7...
5
6
   * @author Bjoern Schiessle
   * @copyright 2014 Bjoern Schiessle <schiessle@owncloud.com>
03e52840d   Kload   Init
7
8
9
10
11
12
13
14
15
16
17
18
19
   *
   * This library is free software; you can redistribute it and/or
   * modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE
   * License as published by the Free Software Foundation; either
   * version 3 of the License, or any later version.
   *
   * This library is distributed in the hope that it will be useful,
   * but WITHOUT ANY WARRANTY; without even the implied warranty of
   * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
   * GNU AFFERO GENERAL PUBLIC LICENSE for more details.
   *
   * You should have received a copy of the GNU Affero General Public
   * License along with this library.  If not, see <http://www.gnu.org/licenses/>.
f7d878ff1   kload   [enh] Update to 7...
20
   *
03e52840d   Kload   Init
21
   */
f7d878ff1   kload   [enh] Update to 7...
22
  require_once __DIR__ . '/base.php';
03e52840d   Kload   Init
23

f7d878ff1   kload   [enh] Update to 7...
24
  class Test_Files_Sharing_Helper extends Test_Files_Sharing_Base {
31b7f2792   Kload   Upgrade to ownclo...
25

f7d878ff1   kload   [enh] Update to 7...
26
27
28
29
30
  	/**
  	 * test set and get share folder
  	 */
  	function testSetGetShareFolder() {
  		$this->assertSame('/', \OCA\Files_Sharing\Helper::getShareFolder());
31b7f2792   Kload   Upgrade to ownclo...
31

f7d878ff1   kload   [enh] Update to 7...
32
  		\OCA\Files_Sharing\Helper::setShareFolder('/Shared');
31b7f2792   Kload   Upgrade to ownclo...
33

f7d878ff1   kload   [enh] Update to 7...
34
35
36
37
  		$this->assertSame('/Shared', \OCA\Files_Sharing\Helper::getShareFolder());
  
  		// cleanup
  		\OCP\Config::deleteSystemValue('share_folder');
a293d369c   Kload   Update sources to...
38

d1bafeea1   Kload   [fix] Upgrade to ...
39
  	}
f7d878ff1   kload   [enh] Update to 7...
40

03e52840d   Kload   Init
41
  }