aboutsummaryrefslogtreecommitdiff
path: root/tests2
diff options
context:
space:
mode:
authorMakoto Onuki <omakoto@google.com>2017-01-12 15:18:59 -0800
committerMakoto Onuki <omakoto@google.com>2017-01-12 15:18:59 -0800
commita4ae2c38359a9732138a13569392a431549735cd (patch)
tree414be6549333ff387bae0ccf9f90f76a749e50d4 /tests2
parenta64a29a2aefbbbc3290e5d4fa4f9f423c2b19846 (diff)
downloadContactsProvider-a4ae2c38359a9732138a13569392a431549735cd.tar.gz
Temporarily disable particularly slow tests
Test: adb shell am instrument -w com.android.providers.contacts.tests2 Bug: 26504707 Change-Id: I565efb552de1c8b834ef913e0643c53eda02810c
Diffstat (limited to 'tests2')
-rw-r--r--tests2/src/com/android/providers/contacts/tests2/AllUriTest.java136
1 files changed, 69 insertions, 67 deletions
diff --git a/tests2/src/com/android/providers/contacts/tests2/AllUriTest.java b/tests2/src/com/android/providers/contacts/tests2/AllUriTest.java
index f7747cc9..2aa6a619 100644
--- a/tests2/src/com/android/providers/contacts/tests2/AllUriTest.java
+++ b/tests2/src/com/android/providers/contacts/tests2/AllUriTest.java
@@ -397,53 +397,54 @@ public class AllUriTest extends AndroidTestCase {
failIfFailed();
}
- /**
- * Make sure all URLs are accessible with a projection.
- */
- public void testSelectWithProjection() {
- for (String[] path : URIs) {
- if (!supportsQuery(path)) continue;
- final Uri uri = getUri(path);
-
- for (String column : getColumns(uri)) {
- // Some columns are not selectable alone due to bugs, and we don't want to fix them
- // in order to avoid expanding the differences between versions, so here're some
- // hacks to make it work...
-
- String[] projection = {column};
-
- final String u = path[0];
- if ((u.startsWith("content://com.android.contacts/status_updates")
- || u.startsWith("content://com.android.contacts/profile/status_updates"))
- && ("im_handle".equals(column)
- || "im_account".equals(column)
- || "protocol".equals(column)
- || "custom_protocol".equals(column)
- || "presence_raw_contact_id".equals(column)
- )) {
- // These columns only show up when the projection contains certain columns.
-
- projection = new String[]{"mode", column};
- } else if ((u.startsWith("content://com.android.contacts/search_suggest_query")
- || u.startsWith("content://contacts/search_suggest_query"))
- && "suggest_intent_action".equals(column)) {
- // Can't be included in the projection due to a bug in GlobalSearchSupport.
- continue;
- } else if (RawContacts.BACKUP_ID.equals(column)) {
- // Some URIs don't support a projection with BAKCUP_ID only.
- projection = new String[]{RawContacts.BACKUP_ID, RawContacts.SOURCE_ID};
- }
-
- checkQueryExecutable(uri,
- projection, // projection
- null, // selection
- null, // selection args
- null // sort order
- );
- }
- }
- failIfFailed();
- }
+// Temporarily disabled due to taking too much time.
+// /**
+// * Make sure all URLs are accessible with a projection.
+// */
+// public void testSelectWithProjection() {
+// for (String[] path : URIs) {
+// if (!supportsQuery(path)) continue;
+// final Uri uri = getUri(path);
+//
+// for (String column : getColumns(uri)) {
+// // Some columns are not selectable alone due to bugs, and we don't want to fix them
+// // in order to avoid expanding the differences between versions, so here're some
+// // hacks to make it work...
+//
+// String[] projection = {column};
+//
+// final String u = path[0];
+// if ((u.startsWith("content://com.android.contacts/status_updates")
+// || u.startsWith("content://com.android.contacts/profile/status_updates"))
+// && ("im_handle".equals(column)
+// || "im_account".equals(column)
+// || "protocol".equals(column)
+// || "custom_protocol".equals(column)
+// || "presence_raw_contact_id".equals(column)
+// )) {
+// // These columns only show up when the projection contains certain columns.
+//
+// projection = new String[]{"mode", column};
+// } else if ((u.startsWith("content://com.android.contacts/search_suggest_query")
+// || u.startsWith("content://contacts/search_suggest_query"))
+// && "suggest_intent_action".equals(column)) {
+// // Can't be included in the projection due to a bug in GlobalSearchSupport.
+// continue;
+// } else if (RawContacts.BACKUP_ID.equals(column)) {
+// // Some URIs don't support a projection with BAKCUP_ID only.
+// projection = new String[]{RawContacts.BACKUP_ID, RawContacts.SOURCE_ID};
+// }
+//
+// checkQueryExecutable(uri,
+// projection, // projection
+// null, // selection
+// null, // selection args
+// null // sort order
+// );
+// }
+// }
+// failIfFailed();
+// }
/**
* Make sure all URLs are accessible with a selection.
@@ -475,7 +476,7 @@ public class AllUriTest extends AndroidTestCase {
// checkQueryExecutable(uri,
// null, // projection
// column + "=?", // selection
-// ARG1, // , // selection args
+// ARG1, // , // selection args
// null // sort order
// );
// }
@@ -483,25 +484,26 @@ public class AllUriTest extends AndroidTestCase {
// failIfFailed();
// }
- /**
- * Make sure all URLs are accessible with an order-by.
- */
- public void testSelectWithSortOrder() {
- for (String[] path : URIs) {
- if (!supportsQuery(path)) continue;
- final Uri uri = getUri(path);
-
- for (String column : getColumns(uri)) {
- checkQueryExecutable(uri,
- null, // projection
- "1=2", // selection
- null, // , // selection args
- column // sort order
- );
- }
- }
- failIfFailed();
- }
+// Temporarily disabled due to taking too much time.
+// /**
+// * Make sure all URLs are accessible with an order-by.
+// */
+// public void testSelectWithSortOrder() {
+// for (String[] path : URIs) {
+// if (!supportsQuery(path)) continue;
+// final Uri uri = getUri(path);
+//
+// for (String column : getColumns(uri)) {
+// checkQueryExecutable(uri,
+// null, // projection
+// "1=2", // selection
+// null, // , // selection args
+// column // sort order
+// );
+// }
+// }
+// failIfFailed();
+// }
/**
* Make sure all URLs are accessible with all arguments.