diff --git a/ElementX/Sources/Services/Notification/Manager/NotificationManager.swift b/ElementX/Sources/Services/Notification/Manager/NotificationManager.swift index d5fd7f7eb0..11fbda7147 100644 --- a/ElementX/Sources/Services/Notification/Manager/NotificationManager.swift +++ b/ElementX/Sources/Services/Notification/Manager/NotificationManager.swift @@ -29,16 +29,16 @@ final class NotificationManager: NSObject, NotificationManagerProtocol { // MARK: NotificationManagerProtocol weak var delegate: NotificationManagerDelegate? - + func start() { - // Not implemented yet - // let replyAction = UNTextInputNotificationAction(identifier: NotificationConstants.Action.inlineReply, - // title: L10n.actionQuickReply, - // options: []) + let replyAction = UNTextInputNotificationAction(identifier: NotificationConstants.Action.inlineReply, + title: L10n.actionQuickReply, + options: []) let messageCategory = UNNotificationCategory(identifier: NotificationConstants.Category.message, - actions: [], + actions: [replyAction], intentIdentifiers: [], options: []) + let inviteCategory = UNNotificationCategory(identifier: NotificationConstants.Category.invite, actions: [], intentIdentifiers: [], diff --git a/UnitTests/Sources/NotificationManager/NotificationManagerTests.swift b/UnitTests/Sources/NotificationManager/NotificationManagerTests.swift index 2755b65e41..a368e4e35a 100644 --- a/UnitTests/Sources/NotificationManager/NotificationManagerTests.swift +++ b/UnitTests/Sources/NotificationManager/NotificationManagerTests.swift @@ -108,15 +108,16 @@ final class NotificationManagerTests: XCTestCase { XCTAssertEqual(request.content.title, "Title") XCTAssertEqual(request.content.subtitle, "Subtitle") } - + func test_whenStart_notificationCategoriesAreSet() throws { - // let replyAction = UNTextInputNotificationAction(identifier: NotificationConstants.Action.inlineReply, - // title: L10n.actionQuickReply, - // options: []) + let replyAction = UNTextInputNotificationAction(identifier: NotificationConstants.Action.inlineReply, + title: L10n.actionQuickReply, + options: []) let messageCategory = UNNotificationCategory(identifier: NotificationConstants.Category.message, - actions: [], + actions: [replyAction], intentIdentifiers: [], options: []) + let inviteCategory = UNNotificationCategory(identifier: NotificationConstants.Category.invite, actions: [], intentIdentifiers: [],