22require_once(__DIR__ . 
"/../BaseNotificationSetUp.php");
 
   31        $group_notification = $this->factory->standardGroup($this->
id);
 
   33        $this->assertInstanceOf(StandardNotificationGroup::class, $group_notification);
 
   34        $this->assertEquals($this->
id, $group_notification->getProviderIdentification());
 
   39        $group_notification = $this->factory->standardGroup($this->
id)->withTitle(
"test");
 
   40        $this->assertEquals(
"test", $group_notification->getTitle());
 
   45        $group_notification = $this->factory->standardGroup($this->
id);
 
   46        $this->assertEquals([], $group_notification->getNotifications());
 
   47        $standard_notification = $this->factory->standard($this->
id);
 
   48        $group_notification->addNotification($standard_notification);
 
   49        $this->assertEquals([$standard_notification], $group_notification->getNotifications());
 
   50        $group_notification->addNotification($standard_notification);
 
   51        $this->assertEquals([$standard_notification,$standard_notification], $group_notification->getNotifications());
 
   56        $group_notification = $this->factory->standardGroup($this->
id);
 
   57        $this->assertEquals(0, $group_notification->getNotificationsCount());
 
   58        $standard_notification = $this->factory->standard($this->
id);
 
   59        $group_notification->addNotification($standard_notification);
 
   60        $this->assertEquals(1, $group_notification->getNotificationsCount());
 
   61        $group_notification->addNotification($standard_notification);
 
   62        $this->assertEquals(2, $group_notification->getNotificationsCount());
 
   67        $group_notification = $this->factory->standardGroup($this->
id);
 
   68        $this->assertEquals(0, $group_notification->getNewNotificationsCount());
 
   69        $standard_notification = $this->factory->standard($this->
id)->withNewAmount(3);
 
   70        $group_notification->addNotification($standard_notification);
 
   71        $this->assertEquals(3, $group_notification->getNewNotificationsCount());
 
   72        $group_notification->addNotification($standard_notification);
 
   73        $this->assertEquals(6, $group_notification->getNewNotificationsCount());
 
   78        $group_notification = $this->factory->standardGroup($this->
id);
 
   79        $this->assertEquals(0, $group_notification->getOldNotificationsCount());
 
   80        $standard_notification = $this->factory->standard($this->
id)->withOldAmount(3);
 
   81        $group_notification->addNotification($standard_notification);
 
   82        $this->assertEquals(3, $group_notification->getOldNotificationsCount());
 
   83        $group_notification->addNotification($standard_notification);
 
   84        $this->assertEquals(6, $group_notification->getOldNotificationsCount());
 
   92        $standard_notification = $this->factory->standard($this->
id);
 
   93        $this->assertEquals($this->
id, $standard_notification->getProviderIdentification());
 
   98        $group_notification = $this->factory->standardGroup($this->
id);
 
   99        $this->assertInstanceOf(
 
  100            StandardNotificationGroupRenderer::class,
 
  101            $group_notification->getRenderer($this->getUIFactory())
 
  107        $callable = 
function (): 
string {
 
  110        $standard_notification = $this->factory->standard($this->
id);
 
  111        $this->assertEquals(
function (): 
void {
 
  112        }, $standard_notification->getOpenedCallable());
 
  113        $standard_notification = $standard_notification->withOpenedCallable($callable);
 
  114        $this->assertEquals($callable, $standard_notification->getOpenedCallable());
 
Class BaseNotificationSetUp.
 
Class StandardNotificationTest.
 
testGetProviderIdentification()
Tests on AbstractBaseNotification.
 
testOldNotificationCount()
 
testNewNotificationCount()
 
Class StandardNotificationGroupRenderer.
 
Class StandardNotificationGroup Groups a set of Notification.