summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChiao Cheng <chiaocheng@google.com>2013-05-09 16:22:25 -0700
committerChiao Cheng <chiaocheng@google.com>2013-05-09 16:22:25 -0700
commit4a732664f285ebe3dcd495c5e94d4043ebd59dcb (patch)
tree770958c67825a0790abe83aff9cabc635eab34e6
parentda51adb4b99894666e7ea91fed0e8afc94162333 (diff)
downloadpackages_providers_ContactsProvider-4a732664f285ebe3dcd495c5e94d4043ebd59dcb.zip
packages_providers_ContactsProvider-4a732664f285ebe3dcd495c5e94d4043ebd59dcb.tar.gz
packages_providers_ContactsProvider-4a732664f285ebe3dcd495c5e94d4043ebd59dcb.tar.bz2
Fix method not found errors for unit test.
Two methods in MoreDatabaseUtils are no longer used after a recent bug fix. But the tests for them are erroring out in userdebug builds because proguard is stripping the methods. Bug: 8894559 Change-Id: Idc2b4c9fd2fd6b58a3c44e5a40dec1b1c582cd2e
-rw-r--r--src/com/android/providers/contacts/database/MoreDatabaseUtils.java4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/com/android/providers/contacts/database/MoreDatabaseUtils.java b/src/com/android/providers/contacts/database/MoreDatabaseUtils.java
index a03fc25..fa186bb 100644
--- a/src/com/android/providers/contacts/database/MoreDatabaseUtils.java
+++ b/src/com/android/providers/contacts/database/MoreDatabaseUtils.java
@@ -16,6 +16,8 @@
package com.android.providers.contacts.database;
+import com.android.providers.contacts.util.NeededForTesting;
+
/**
* Static methods for database operations.
*/
@@ -40,6 +42,7 @@ public class MoreDatabaseUtils {
* @param field The field that was originally used to create the index.
* @return The drop index sql statement.
*/
+ @NeededForTesting
public static String buildDropIndexSql(String table, String field) {
return "DROP INDEX IF EXISTS " + buildIndexName(table, field);
}
@@ -63,6 +66,7 @@ public class MoreDatabaseUtils {
* @param numArgs The number of arguments.
* @return A string that can be used for bind args in a sql where clause.
*/
+ @NeededForTesting
public static String buildBindArgString(int numArgs) {
final StringBuilder sb = new StringBuilder();
String delimiter = "";