Add SuppressWarnings for new Error Prone checker
This file is intentionally using Optional wrong as part of its tests.
That's fine, but we plan to make it a build error to do this
accidentally, so this file will need a suppression.
Change-Id: I76b22f780f18cb674b0a010455058b0e2a8fb0d2
diff --git a/user/test/com/google/gwt/emultest/java8/util/OptionalTest.java b/user/test/com/google/gwt/emultest/java8/util/OptionalTest.java
index 77ce11b..ad5fa51 100644
--- a/user/test/com/google/gwt/emultest/java8/util/OptionalTest.java
+++ b/user/test/com/google/gwt/emultest/java8/util/OptionalTest.java
@@ -196,6 +196,7 @@
assertSame(REFERENCE, present.orElse(OTHER_REFERENCE));
}
+ @SuppressWarnings("DangerousLiteralNull") // Intentionally misusing Optional to test bug parity.
public void testOrElseGet() {
// empty case
try {
@@ -216,6 +217,7 @@
}));
}
+ @SuppressWarnings("DangerousLiteralNull") // Intentionally misusing Optional to test bug parity.
public void testOrElseThrow() {
// empty case
try {