diff options
author | wsmlby <wsmlby@google.com> | 2014-10-01 12:47:25 -0700 |
---|---|---|
committer | Bingyan Liu <wsmlby@google.com> | 2014-10-01 20:57:55 +0000 |
commit | 6bd30ee1a252e41a3fcdcb1f11dc031da5895698 (patch) | |
tree | 9dd9211eff4430e79a7deeefb1af84c9281237a1 /tests/Compatibility/src/com | |
parent | 9cf01b63cb0023aec0e05b1ce050ff572532b876 (diff) | |
download | frameworks_base-6bd30ee1a252e41a3fcdcb1f11dc031da5895698.zip frameworks_base-6bd30ee1a252e41a3fcdcb1f11dc031da5895698.tar.gz frameworks_base-6bd30ee1a252e41a3fcdcb1f11dc031da5895698.tar.bz2 |
Throw error when no intent can be found
bug: 17396762
Change-Id: I10502d5d1e2332d9e6820ee645234c125e937b7a
Diffstat (limited to 'tests/Compatibility/src/com')
-rw-r--r-- | tests/Compatibility/src/com/android/compatibilitytest/AppCompatibility.java | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/tests/Compatibility/src/com/android/compatibilitytest/AppCompatibility.java b/tests/Compatibility/src/com/android/compatibilitytest/AppCompatibility.java index 5794b2b..dd823ae 100644 --- a/tests/Compatibility/src/com/android/compatibilitytest/AppCompatibility.java +++ b/tests/Compatibility/src/com/android/compatibilitytest/AppCompatibility.java @@ -155,16 +155,12 @@ public class AppCompatibility extends InstrumentationTestCase { homeIntent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK); Intent intent; if (isleanback) { - Log.d(TAG, "Leanback and relax!"); + Log.d(TAG, "Leanback and relax! " + packageName); intent = mPackageManager.getLeanbackLaunchIntentForPackage(packageName); } else { intent = mPackageManager.getLaunchIntentForPackage(packageName); } - // Skip if the apk does not have a launch intent. - if (intent == null) { - Log.d(TAG, "Skipping " + packageName + "; missing launch intent"); - return null; - } + assertNotNull("Skipping " + packageName + "; missing launch intent", intent); String processName = getProcessName(packageName); |