diff --git a/src/Resolver/NotificationResolver.php b/src/Resolver/NotificationResolver.php index 3d42ada..885f706 100644 --- a/src/Resolver/NotificationResolver.php +++ b/src/Resolver/NotificationResolver.php @@ -216,6 +216,8 @@ public function resolve(array $data): array ->setAllowedTypes('summary_arg', 'string') ->setDefined('summary_arg_count') ->setAllowedTypes('summary_arg_count', 'int') + ->setDefined('ios_interruption_level') + ->setAllowedTypes('ios_interruption_level', 'string') ->setDefined('ttl') ->setAllowedTypes('ttl', 'int') ->setDefined('priority') diff --git a/tests/Fixtures/notifications_get_all.json b/tests/Fixtures/notifications_get_all.json index 2a8d81e..157929e 100644 --- a/tests/Fixtures/notifications_get_all.json +++ b/tests/Fixtures/notifications_get_all.json @@ -85,6 +85,7 @@ "tags": null, "filters": null, "template_id": null, + "ios_interruption_level": "active", "ttl": null, "url": "https://mysite.com", "web_url": null, diff --git a/tests/NotificationsTest.php b/tests/NotificationsTest.php index 81be6d9..6987375 100644 --- a/tests/NotificationsTest.php +++ b/tests/NotificationsTest.php @@ -161,6 +161,7 @@ public function testGetAll(): void 'tags' => null, 'filters' => null, 'template_id' => null, + 'ios_interruption_level' => 'active', 'ttl' => null, 'url' => 'https://mysite.com', 'web_url' => null, diff --git a/tests/Resolver/NotificationResolverTest.php b/tests/Resolver/NotificationResolverTest.php index 6881981..205d66d 100644 --- a/tests/Resolver/NotificationResolverTest.php +++ b/tests/Resolver/NotificationResolverTest.php @@ -114,6 +114,7 @@ public function testResolveWithValidValues(): void 'thread_id' => 'value', 'summary_arg' => 'value', 'summary_arg_count' => 10, + 'ios_interruption_level' => 'value', 'ttl' => 23, 'priority' => 10, 'app_id' => 'value', @@ -212,6 +213,7 @@ public function wrongValueTypesProvider(): iterable yield [['android_group_message' => 666]]; yield [['adm_group' => 666]]; yield [['adm_group_message' => 666]]; + yield [['ios_interruption_level' => 666]]; yield [['ttl' => 'wrongType']]; yield [['priority' => 'wrongType']]; yield [['app_id' => 666]];