diff options
author | Lukas Reschke <lukas@statuscode.ch> | 2017-08-18 15:39:10 +0200 |
---|---|---|
committer | Lukas Reschke <lukas@statuscode.ch> | 2017-08-18 15:39:10 +0200 |
commit | f8b4b2c4998239fbbee7c7e5b2de0654e66c46fb (patch) | |
tree | a7a95a0e22c2bf512cac9f817d6c17eca84d43d2 /apps | |
parent | 231cffffb9084ed1b7779f40ec07ad617ec71a30 (diff) | |
download | nextcloud-server-f8b4b2c4998239fbbee7c7e5b2de0654e66c46fb.tar.gz nextcloud-server-f8b4b2c4998239fbbee7c7e5b2de0654e66c46fb.zip |
Fix PHPUnit warnings
```
1) OCA\FederatedFileSharing\Tests\Settings\AdminTest::testGetForm with data set #0 (true)
PHPUnit_Framework_TestCase::getMock() is deprecated, use PHPUnit_Framework_TestCase::createMock() or PHPUnit_Framework_TestCase::getMockBuilder() instead
2) OCA\FederatedFileSharing\Tests\Settings\AdminTest::testGetForm with data set #1 (false)
PHPUnit_Framework_TestCase::getMock() is deprecated, use PHPUnit_Framework_TestCase::createMock() or PHPUnit_Framework_TestCase::getMockBuilder() instead
3) OCA\FederatedFileSharing\Tests\Settings\AdminTest::testGetSection
PHPUnit_Framework_TestCase::getMock() is deprecated, use PHPUnit_Framework_TestCase::createMock() or PHPUnit_Framework_TestCase::getMockBuilder() instead
4) OCA\FederatedFileSharing\Tests\Settings\AdminTest::testGetPriority
PHPUnit_Framework_TestCase::getMock() is deprecated, use PHPUnit_Framework_TestCase::createMock() or PHPUnit_Framework_TestCase::getMockBuilder() instead
```
Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
Diffstat (limited to 'apps')
-rw-r--r-- | apps/federatedfilesharing/tests/Settings/AdminTest.php | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/apps/federatedfilesharing/tests/Settings/AdminTest.php b/apps/federatedfilesharing/tests/Settings/AdminTest.php index ce47ffb2385..183cd055686 100644 --- a/apps/federatedfilesharing/tests/Settings/AdminTest.php +++ b/apps/federatedfilesharing/tests/Settings/AdminTest.php @@ -23,6 +23,7 @@ namespace OCA\FederatedFileSharing\Tests\Settings; +use OCA\FederatedFileSharing\FederatedShareProvider; use OCA\FederatedFileSharing\Settings\Admin; use OCP\AppFramework\Http\TemplateResponse; use OCP\GlobalScale\IConfig; @@ -38,9 +39,8 @@ class AdminTest extends TestCase { public function setUp() { parent::setUp(); - $this->federatedShareProvider = $this->getMockBuilder('\OCA\FederatedFileSharing\FederatedShareProvider') - ->disableOriginalConstructor()->getMock(); - $this->gsConfig = $this->getMock(IConfig::class); + $this->federatedShareProvider = $this->createMock(FederatedShareProvider::class); + $this->gsConfig = $this->createMock(IConfig::class); $this->admin = new Admin( $this->federatedShareProvider, $this->gsConfig |