diff options
author | John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com> | 2018-12-05 19:41:19 +0100 |
---|---|---|
committer | John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com> | 2018-12-05 21:13:57 +0100 |
commit | 2be63bcb6a772dbb5600e116595751fed6ac261e (patch) | |
tree | 27d396d7d042af5ed25e493e4943155e01097ea0 /tests | |
parent | 5e44699139d59e66d65586adc3da8e4ee1c4ebde (diff) | |
download | nextcloud-server-2be63bcb6a772dbb5600e116595751fed6ac261e.tar.gz nextcloud-server-2be63bcb6a772dbb5600e116595751fed6ac261e.zip |
Log and continue on Dav reader failure
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
Diffstat (limited to 'tests')
-rw-r--r-- | tests/lib/Repair/SetVcardDatabaseUIDTest.php | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/tests/lib/Repair/SetVcardDatabaseUIDTest.php b/tests/lib/Repair/SetVcardDatabaseUIDTest.php index 97da3c6a901..2939528a21a 100644 --- a/tests/lib/Repair/SetVcardDatabaseUIDTest.php +++ b/tests/lib/Repair/SetVcardDatabaseUIDTest.php @@ -24,6 +24,8 @@ namespace Test\Repair; use OCP\IConfig; +use OCP\ILogger; +use OCP\Migration\IOutput; use OC\Repair\NC15\SetVcardDatabaseUID; use Test\TestCase; @@ -38,11 +40,15 @@ class SetVcardDatabaseUIDTest extends TestCase { /** @var IConfig */ private $config; + /** @var Ilogger */ + private $logger; + protected function setUp() { parent::setUp(); $this->config = $this->createMock(IConfig::class); - $this->repair = new SetVcardDatabaseUID(\OC::$server->getDatabaseConnection(), $this->config); + $this->logger = $this->createMock(Ilogger::class); + $this->repair = new SetVcardDatabaseUID(\OC::$server->getDatabaseConnection(), $this->config, $this->logger); } protected function tearDown() { @@ -86,7 +92,8 @@ class SetVcardDatabaseUIDTest extends TestCase { * @param string|boolean $expected */ public function testExtractUIDFromVcard($from, $expected) { - $uid = $this->invokePrivate($this->repair, 'getUid', ['carddata' => $from]); + $output = $this->createMock(IOutput::class); + $uid = $this->invokePrivate($this->repair, 'getUid', ['carddata' => $from, 'output' => $output]); $this->assertEquals($expected, $uid); } |