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

Unified Diff: testing/android/proguard_for_test.flags

Issue 2767783004: Add proguard flags for JUnit4 tests (Closed)
Patch Set: Created 3 years, 9 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: testing/android/proguard_for_test.flags
diff --git a/testing/android/proguard_for_test.flags b/testing/android/proguard_for_test.flags
index 3326074db6ab3d562af70be4951741d57bab9b33..6bf0bbee973153ba2c2664291f88dcf76e352211 100644
--- a/testing/android/proguard_for_test.flags
+++ b/testing/android/proguard_for_test.flags
@@ -7,11 +7,26 @@
# correctness of the .apk we are testing, since it will apply to that .apk as
# well.
-# We want all tests to stick around.
+# Keep all junit3 tests
-keep class * extends junit.framework.TestCase {
*;
}
+# Keep all junit4 tests
+-keep @**.RunWith class * {
+ *;
+}
+
+# Keep any class inherited from android testing support lib
jbudorick 2017/03/22 00:17:20 Why do we need these two additions?
the real yoland 2017/03/22 00:28:15 AndroidJUnitRunner reflectively calls for class ru
+-keep class * extends android.support.test.** {
+ *;
+}
+
+# Keep any class inherited from junit 4 library
+-keep class * extends org.junit.** {
+ *;
+}
+
# TODO(yfriedman): Remove when crbug.com/488192 is fixed.
-dontwarn org.apache.http.conn.scheme.LayeredSocketFactory
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698