Fix instrumentation tests by forcing channel id usage to init channels.

This commit is contained in:
Cody Henthorne
2022-12-08 12:15:17 -05:00
parent 51015dc898
commit fb0aa55cbb
23 changed files with 49 additions and 48 deletions

View File

@@ -51,7 +51,7 @@ public final class GenericForegroundService extends Service {
private final LinkedHashMap<Integer, Entry> allActiveMessages = new LinkedHashMap<>();
private static final Entry DEFAULTS = new Entry("", NotificationChannels.OTHER, R.drawable.ic_notification, -1, 0, 0, false);
private static final Entry DEFAULTS = new Entry("", NotificationChannels.getInstance().OTHER, R.drawable.ic_notification, -1, 0, 0, false);
private @Nullable Entry lastPosted;

View File

@@ -263,7 +263,7 @@ public class KeyCachingService extends Service {
}
Log.i(TAG, "foregrounding KCS");
NotificationCompat.Builder builder = new NotificationCompat.Builder(this, NotificationChannels.LOCKED_STATUS);
NotificationCompat.Builder builder = new NotificationCompat.Builder(this, NotificationChannels.getInstance().LOCKED_STATUS);
builder.setContentTitle(getString(R.string.KeyCachingService_passphrase_cached));
builder.setContentText(getString(R.string.KeyCachingService_signal_passphrase_cached));

View File

@@ -64,7 +64,7 @@ public class UpdateApkReadyListener extends BroadcastReceiver {
PendingIntent pendingIntent = PendingIntent.getActivity(context, 0, intent, PendingIntentFlags.mutable());
Notification notification = new NotificationCompat.Builder(context, NotificationChannels.APP_UPDATES)
Notification notification = new NotificationCompat.Builder(context, NotificationChannels.getInstance().APP_UPDATES)
.setOngoing(true)
.setContentTitle(context.getString(R.string.UpdateApkReadyListener_Signal_update))
.setContentText(context.getString(R.string.UpdateApkReadyListener_a_new_version_of_signal_is_available_tap_to_update))