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
path: root/apps
diff options
context:
space:
mode:
authorJoas Schilling <coding@schilljs.com>2022-06-07 21:40:55 +0300
committerJoas Schilling <coding@schilljs.com>2022-06-07 21:40:55 +0300
commit50c697dbd4a8f8ab2f372944c0a55ad89f201f40 (patch)
tree7fdcf9daf4670d1016b3a79b13d11463991aed02 /apps
parenta33310f1b13b64fa5c88b4d5f2ecbf3d9d3bb569 (diff)
Fix unit tests
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'apps')
-rw-r--r--apps/files_sharing/lib/Controller/RemoteController.php4
-rw-r--r--apps/files_sharing/tests/ApiTest.php2
-rw-r--r--apps/files_sharing/tests/Controller/ShareAPIControllerTest.php10
3 files changed, 8 insertions, 8 deletions
diff --git a/apps/files_sharing/lib/Controller/RemoteController.php b/apps/files_sharing/lib/Controller/RemoteController.php
index 75684220c52..47523e08639 100644
--- a/apps/files_sharing/lib/Controller/RemoteController.php
+++ b/apps/files_sharing/lib/Controller/RemoteController.php
@@ -86,7 +86,7 @@ class RemoteController extends OCSController {
$this->logger->error('Could not accept federated share with id: ' . $id,
['app' => 'files_sharing']);
- throw new OCSNotFoundException('wrong share ID, share doesn\'t exist.');
+ throw new OCSNotFoundException('wrong share ID, share does not exist.');
}
/**
@@ -106,7 +106,7 @@ class RemoteController extends OCSController {
// Make sure the user has no notification for something that does not exist anymore.
$this->externalManager->processNotification($id);
- throw new OCSNotFoundException('wrong share ID, share doesn\'t exist.');
+ throw new OCSNotFoundException('wrong share ID, share does not exist.');
}
/**
diff --git a/apps/files_sharing/tests/ApiTest.php b/apps/files_sharing/tests/ApiTest.php
index c7159e82163..a16a1aaf383 100644
--- a/apps/files_sharing/tests/ApiTest.php
+++ b/apps/files_sharing/tests/ApiTest.php
@@ -929,7 +929,7 @@ class ApiTest extends TestCase {
$ocs->getShare(0);
$this->fail();
} catch (OCSNotFoundException $e) {
- $this->assertEquals('Wrong share ID, share doesn\'t exist', $e->getMessage());
+ $this->assertEquals('Wrong share ID, share does not exist', $e->getMessage());
}
$ocs->cleanup();
}
diff --git a/apps/files_sharing/tests/Controller/ShareAPIControllerTest.php b/apps/files_sharing/tests/Controller/ShareAPIControllerTest.php
index 5555aef1425..fd5580f19a7 100644
--- a/apps/files_sharing/tests/Controller/ShareAPIControllerTest.php
+++ b/apps/files_sharing/tests/Controller/ShareAPIControllerTest.php
@@ -196,7 +196,7 @@ class ShareAPIControllerTest extends TestCase {
public function testDeleteShareShareNotFound() {
$this->expectException(\OCP\AppFramework\OCS\OCSNotFoundException::class);
- $this->expectExceptionMessage('Wrong share ID, share doesn\'t exist');
+ $this->expectExceptionMessage('Wrong share ID, share does not exist');
$this->shareManager
->expects($this->exactly(6))
@@ -433,7 +433,7 @@ class ShareAPIControllerTest extends TestCase {
*/
public function testDeleteSharedWithGroupIDontBelongTo() {
$this->expectException(\OCP\AppFramework\OCS\OCSNotFoundException::class);
- $this->expectExceptionMessage('Wrong share ID, share doesn\'t exist');
+ $this->expectExceptionMessage('Wrong share ID, share does not exist');
$node = $this->getMockBuilder(File::class)->getMock();
@@ -498,7 +498,7 @@ class ShareAPIControllerTest extends TestCase {
->with('ocinternal:42', 'currentUser')
->will($this->throwException(new \OC\Share20\Exception\ShareNotFound()));
- $expected = new \OC\OCS\Result(null, 404, 'wrong share ID, share doesn\'t exist.');
+ $expected = new \OC\OCS\Result(null, 404, 'wrong share ID, share does not exist.');
$this->assertEquals($expected, $this->ocs->getShare(42));
}
*/
@@ -808,7 +808,7 @@ class ShareAPIControllerTest extends TestCase {
public function testGetShareInvalidNode() {
$this->expectException(\OCP\AppFramework\OCS\OCSNotFoundException::class);
- $this->expectExceptionMessage('Wrong share ID, share doesn\'t exist');
+ $this->expectExceptionMessage('Wrong share ID, share does not exist');
$share = \OC::$server->getShareManager()->newShare();
$share->setSharedBy('initiator')
@@ -2602,7 +2602,7 @@ class ShareAPIControllerTest extends TestCase {
public function testUpdateShareCantAccess() {
$this->expectException(\OCP\AppFramework\OCS\OCSNotFoundException::class);
- $this->expectExceptionMessage('Wrong share ID, share doesn\'t exist');
+ $this->expectExceptionMessage('Wrong share ID, share does not exist');
$node = $this->getMockBuilder(Folder::class)->getMock();
$share = $this->newShare();