mirror of
https://github.com/nextcloud/server.git
synced 2026-02-28 12:30:40 -05:00
Cleanup comment tests
Signed-off-by: Joas Schilling <coding@schilljs.com>
This commit is contained in:
parent
315645ada3
commit
bb84db02cb
2 changed files with 4 additions and 13 deletions
|
|
@ -23,7 +23,6 @@ namespace OCA\Comments\Notification;
|
|||
|
||||
use OCP\Comments\CommentsEvent;
|
||||
use OCP\Comments\IComment;
|
||||
use OCP\IURLGenerator;
|
||||
use OCP\IUserManager;
|
||||
use OCP\Notification\IManager;
|
||||
|
||||
|
|
@ -34,25 +33,19 @@ class Listener {
|
|||
/** @var IUserManager */
|
||||
protected $userManager;
|
||||
|
||||
/** @var IURLGenerator */
|
||||
protected $urlGenerator;
|
||||
|
||||
/**
|
||||
* Listener constructor.
|
||||
*
|
||||
* @param IManager $notificationManager
|
||||
* @param IUserManager $userManager
|
||||
* @param IURLGenerator $urlGenerator
|
||||
*/
|
||||
public function __construct(
|
||||
IManager $notificationManager,
|
||||
IUserManager $userManager,
|
||||
IURLGenerator $urlGenerator
|
||||
IUserManager $userManager
|
||||
) {
|
||||
|
||||
$this->notificationManager = $notificationManager;
|
||||
$this->userManager = $userManager;
|
||||
$this->urlGenerator = $urlGenerator;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -46,14 +46,12 @@ class ListenerTest extends TestCase {
|
|||
protected function setUp() {
|
||||
parent::setUp();
|
||||
|
||||
$this->notificationManager = $this->getMockBuilder('\OCP\Notification\IManager')->getMock();
|
||||
$this->userManager = $this->getMockBuilder('\OCP\IUserManager')->getMock();
|
||||
$this->urlGenerator = $this->getMockBuilder('OCP\IURLGenerator')->getMock();
|
||||
$this->notificationManager = $this->createMock(\OCP\Notification\IManager::class);
|
||||
$this->userManager = $this->createMock(\OCP\IUserManager::class);
|
||||
|
||||
$this->listener = new Listener(
|
||||
$this->notificationManager,
|
||||
$this->userManager,
|
||||
$this->urlGenerator
|
||||
$this->userManager
|
||||
);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue