protected function setUp()
 {
     parent::setUp();
     $this->manager = $this->getMockBuilder('OCA\\AnnouncementCenter\\Manager')->disableOriginalConstructor()->getMock();
     $this->l = $this->getMockBuilder('OCP\\IL10N')->disableOriginalConstructor()->getMock();
     $this->l->expects($this->any())->method('t')->willReturnCallback(function ($string, $args) {
         return vsprintf($string, $args);
     });
     $this->factory = $this->getMockBuilder('OCP\\L10N\\IFactory')->disableOriginalConstructor()->getMock();
     $this->factory->expects($this->any())->method('get')->willReturn($this->l);
     $this->notifier = new NotificationsNotifier($this->manager, $this->factory);
 }
 protected function setUp()
 {
     parent::setUp();
     $this->request = $this->getMockBuilder('OCP\\IRequest')->disableOriginalConstructor()->getMock();
     $this->groupManager = $this->getMockBuilder('OCP\\IGroupManager')->disableOriginalConstructor()->getMock();
     $this->userManager = $this->getMockBuilder('OCP\\IUserManager')->disableOriginalConstructor()->getMock();
     $this->activityManager = $this->getMockBuilder('OCP\\Activity\\IManager')->disableOriginalConstructor()->getMock();
     $this->notificationManager = $this->getMockBuilder('OC\\Notification\\IManager')->disableOriginalConstructor()->getMock();
     $this->l = $this->getMockBuilder('OCP\\IL10N')->disableOriginalConstructor()->getMock();
     $this->l->expects($this->any())->method('t')->willReturnCallback(function ($string, $args) {
         return vsprintf($string, $args);
     });
     $this->urlGenerator = $this->getMockBuilder('OCP\\IURLGenerator')->disableOriginalConstructor()->getMock();
     $this->manager = $this->getMockBuilder('OCA\\AnnouncementCenter\\Manager')->disableOriginalConstructor()->getMock();
 }
 protected function setUp()
 {
     parent::setUp();
     $this->manager = new Manager(\OC::$server->getDatabaseConnection());
 }
 protected function setUp()
 {
     parent::setUp();
     $this->app = new Application();
     $this->container = $this->app->getContainer();
 }