-
Notifications
You must be signed in to change notification settings - Fork 13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: Add Push Primer feature using Custom Json (RMCCX-6702) #322
Merged
SoumenRautray
merged 15 commits into
rakutentech:master
from
SoumenRautray:RMCCX-6702_CustomJson
Aug 6, 2024
Merged
Changes from 4 commits
Commits
Show all changes
15 commits
Select commit
Hold shift + click to select a range
0d7c876
chore: Add Push Primer feature using Custom Json (RMCCX-6702)
SoumenRautray e1120b0
chore: update test cases (RMCCX-6702)
SoumenRautray a83e4be
chore: code refactor (RMCCX-6702)
SoumenRautray 92e86c3
chore: fix CI error (RMCCX-6702)
SoumenRautray 0555fe7
chore: address review comments (RMCCX-6702)
SoumenRautray 59407d7
chore: refactor code (RMCCX-6702)
SoumenRautray 89b997a
chore: add check for enabling pushPrimer only for RMC (RMCCX-6702)
SoumenRautray 6887b63
chore: add test cases for push Primer (RMCCX-6702)
SoumenRautray 00a9a65
chore: code refactor (RMCCX-6702)
SoumenRautray 47cd413
chore: disable pushprimer campaign for IAM (RMCCX-6702)
SoumenRautray 6e993b4
chore: refactor code and add new test cases (RMCCX-6702)
SoumenRautray 570a9c5
chore: add changeLog changes (RMCCX-6702)
SoumenRautray 84a52ef
chore: address review comments, refactor code and test cases (RMCCX-6…
SoumenRautray 9371743
chore: Fix Test case failures (RMCCX-6702)
SoumenRautray 72c7f27
chore: test case refactor (RMCCX-6702)
SoumenRautray File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -21,3 +21,27 @@ extension UNUserNotificationCenter: RemoteNotificationRequestable { | |
} | ||
} | ||
} | ||
|
||
protocol UserNotificationCenter { | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. make use of |
||
func getNotificationSettings(completionHandler: @escaping (NotificationSettingsProtocol) -> Void) | ||
} | ||
|
||
protocol NotificationSettingsProtocol { | ||
var authorizationStatus: UNAuthorizationStatus { get } | ||
} | ||
|
||
class UNUserNotificationService: UserNotificationCenter { | ||
private let center: UNUserNotificationCenter | ||
|
||
init(center: UNUserNotificationCenter = UNUserNotificationCenter.current()) { | ||
self.center = center | ||
} | ||
|
||
func getNotificationSettings(completionHandler: @escaping (NotificationSettingsProtocol) -> Void) { | ||
center.getNotificationSettings { settings in | ||
completionHandler(settings as NotificationSettingsProtocol) | ||
} | ||
} | ||
} | ||
|
||
extension UNNotificationSettings: NotificationSettingsProtocol {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Change this to previous implementation where it was relay on
.authorized
else it wouldn't work when status wasprovisional
.