aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSiva Velusamy <vsiva@google.com>2014-04-22 23:10:53 +0000
committerGerrit Code Review <noreply-gerritcodereview@google.com>2014-04-22 23:10:53 +0000
commit0c5d08da8a14a3ec54578270036012829de97ef2 (patch)
tree21d9f5ae73efe49dff0a5594e8d25e305dabdf86
parent326b951d7e963873aa82065a47bd8ea150f2d225 (diff)
parent0b6a13faa7db9de24b3e93aa627ff2886c723be5 (diff)
downloadsdk-0c5d08da8a14a3ec54578270036012829de97ef2.zip
sdk-0c5d08da8a14a3ec54578270036012829de97ef2.tar.gz
sdk-0c5d08da8a14a3ec54578270036012829de97ef2.tar.bz2
Merge "Relax requirement for instrumentation test runners." into idea133
-rw-r--r--eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/launch/junit/InstrumentationRunnerValidator.java8
1 files changed, 5 insertions, 3 deletions
diff --git a/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/launch/junit/InstrumentationRunnerValidator.java b/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/launch/junit/InstrumentationRunnerValidator.java
index b494f62..54fd207 100644
--- a/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/launch/junit/InstrumentationRunnerValidator.java
+++ b/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/launch/junit/InstrumentationRunnerValidator.java
@@ -134,13 +134,15 @@ class InstrumentationRunnerValidator {
}
// check if this instrumentation is the standard test runner
if (!instrumentation.equals(SdkConstants.CLASS_INSTRUMENTATION_RUNNER)) {
- // check if it extends the standard test runner
+ // Ideally, we'd check if the class extends instrumentation test runner.
+ // However, the Google Instrumentation Test Runner extends Google Instrumentation, and not a test runner,
+ // so we just check that the super class is Instrumentation.
String result = BaseProjectHelper.testClassForManifest(mJavaProject,
- instrumentation, SdkConstants.CLASS_INSTRUMENTATION_RUNNER, true);
+ instrumentation, SdkConstants.CLASS_INSTRUMENTATION, true);
if (result != BaseProjectHelper.TEST_CLASS_OK) {
return String.format(
LaunchMessages.InstrValidator_WrongRunnerTypeMsg_s,
- SdkConstants.CLASS_INSTRUMENTATION_RUNNER);
+ SdkConstants.CLASS_INSTRUMENTATION);
}
}
return INSTRUMENTATION_OK;