Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/server.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristoph Wurst <christoph@winzerhof-wurst.at>2020-03-26 00:21:27 +0300
committerChristoph Wurst <christoph@winzerhof-wurst.at>2020-03-26 00:21:27 +0300
commit2ee65f177e4f7e09ad2287f14d564e7068d322fb (patch)
tree39075e87ea7927e20e8956824cb7c49bf626b178 /tests/lib/AllConfigTest.php
parent3cf321fdfc4235a87015a9af2f59c63220016c65 (diff)
Use the shorter phpunit syntax for mocked return values
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
Diffstat (limited to 'tests/lib/AllConfigTest.php')
-rw-r--r--tests/lib/AllConfigTest.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/lib/AllConfigTest.php b/tests/lib/AllConfigTest.php
index 80ddcbbd354..97af541085b 100644
--- a/tests/lib/AllConfigTest.php
+++ b/tests/lib/AllConfigTest.php
@@ -190,7 +190,7 @@ class AllConfigTest extends \Test\TestCase {
->disableOriginalConstructor()->getMock();
$resultMock->expects($this->once())
->method('fetchColumn')
- ->will($this->returnValue('valueSetUnchanged'));
+ ->willReturn('valueSetUnchanged');
$connectionMock = $this->createMock(IDBConnection::class);
$connectionMock->expects($this->once())
@@ -198,7 +198,7 @@ class AllConfigTest extends \Test\TestCase {
->with($this->equalTo('SELECT `configvalue` FROM `*PREFIX*preferences` '.
'WHERE `userid` = ? AND `appid` = ? AND `configkey` = ?'),
$this->equalTo(array('userSetUnchanged', 'appSetUnchanged', 'keySetUnchanged')))
- ->will($this->returnValue($resultMock));
+ ->willReturn($resultMock);
$connectionMock->expects($this->never())
->method('executeUpdate');
@@ -411,7 +411,7 @@ class AllConfigTest extends \Test\TestCase {
->method('getValue')
->with($this->equalTo('dbtype'),
$this->equalTo('sqlite'))
- ->will($this->returnValue(\OC::$server->getConfig()->getSystemValue('dbtype', 'sqlite')));
+ ->willReturn(\OC::$server->getConfig()->getSystemValue('dbtype', 'sqlite'));
$config = $this->getConfig($systemConfig);
// preparation - add something to the database