Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1205)

Unified Diff: chrome/android/junit/src/org/chromium/chrome/browser/notifications/NotificationPlatformBridgeUnitTest.java

Issue 2895293002: Android: tidy up outdated version checks. (Closed)
Patch Set: Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/android/junit/src/org/chromium/chrome/browser/notifications/NotificationPlatformBridgeUnitTest.java
diff --git a/chrome/android/junit/src/org/chromium/chrome/browser/notifications/NotificationPlatformBridgeUnitTest.java b/chrome/android/junit/src/org/chromium/chrome/browser/notifications/NotificationPlatformBridgeUnitTest.java
index 2bb84bc738b82baaae2d6c1911180f051f70f20d..e94d8a4fee1417709b2f2ef0c464bbcc9acf03af 100644
--- a/chrome/android/junit/src/org/chromium/chrome/browser/notifications/NotificationPlatformBridgeUnitTest.java
+++ b/chrome/android/junit/src/org/chromium/chrome/browser/notifications/NotificationPlatformBridgeUnitTest.java
@@ -15,7 +15,6 @@ import android.os.Build;
import org.junit.After;
import org.junit.Test;
import org.junit.runner.RunWith;
-
import org.robolectric.annotation.Config;
import org.chromium.base.CommandLine;
@@ -65,9 +64,7 @@ public class NotificationPlatformBridgeUnitTest {
CommandLine.reset();
CommandLine.init(null);
- boolean isNougatOrNewer = Build.VERSION.CODENAME.equals("N")
- || Build.VERSION.SDK_INT > 23 /* Build.VERSION_CODES.M */;
- if (isNougatOrNewer) {
+ if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.N) {
// Without comand line flags, custom layouts are always disabled on Nougat+.
assertFalse(NotificationPlatformBridge.useCustomLayouts(false /* hasImage */));
assertFalse(NotificationPlatformBridge.useCustomLayouts(true /* hasImage */));

Powered by Google App Engine
This is Rietveld 408576698