Skip to content

Commit

Permalink
fixup
Browse files Browse the repository at this point in the history
Signed-off-by: Ferdinand Thiessen <[email protected]>
  • Loading branch information
susnux committed Jan 16, 2024
1 parent 24f2805 commit 807b665
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions tests/CurrentUserTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,11 @@
use OCA\Activity\CurrentUser;
use OCP\IRequest;
use OCP\IUser;
use OCP\IUserSession;
use OCP\Share\Exceptions\ShareNotFound;
use OCP\Share\IShare;
use PHPUnit\Framework\MockObject\MockObject;
use OCP\IUserSession;
use OCP\Share\IManager;
use PHPUnit\Framework\MockObject\MockObject;

/**
* Class CurrentUserTest
Expand All @@ -45,15 +45,12 @@ class CurrentUserTest extends TestCase {
/** @var IManager|MockObject */
protected $shareManager;

/**
*
*/

protected function setUp(): void {
parent::setUp();

$this->request = $this->getMockBuilder(IRequest::class)
->disableOriginalConstructor()
->addMethods(['__get'])
->getMock();
$this->userSession = $this->createMock(IUserSession::class);
$this->shareManager = $this->createMock(IManager::class);
Expand Down Expand Up @@ -189,7 +186,7 @@ public function dataGetCloudIDFromToken(): array {
public function testGetCloudIDFromToken(array $server, $share, ?string $expected): void {
$instance = $this->getInstance();

$this->request->server = $server;
$this->request->method('__get')->with('server')->willReturn($server);

if ($share === null) {
$this->shareManager->expects($this->never())
Expand Down

0 comments on commit 807b665

Please sign in to comment.