summaryrefslogtreecommitdiffstats
path: root/tests/src
Commit message (Collapse)AuthorAgeFilesLines
...
* Make sure to rebuild search index on locale changes...Makoto Onuki2012-10-011-0/+52
| | | | | | | | | | | | | | | | | so that search will still work even after changing the locale. - Rebuild the search index upon locale changes, as it contains locale-sensitive data. - Also make sure to update the in-memory collator in NameNormalizer upon locale changes. - Rebuild the search index on the next db upgrade in order to fix the search index which already contains invalid data. Bug 7251461 Change-Id: Id579a67de792a52a0091bf76d7c5d374f76f1639
* Merge "Send a broadcast when profile changes" into jb-mr1-devMakoto Onuki2012-09-121-0/+11
|\
| * Send a broadcast when profile changesMakoto Onuki2012-09-121-0/+11
| | | | | | | | | | | | Bug 7148705 Change-Id: I3df22b7fc18a106f221f022f222d8fee566a24af
* | Skip suffix match if mUseStrictPhoneNumberComparison is trueYorke Lee2012-09-121-0/+58
| | | | | | | | | | | | | | Don't do the suffix match during the phone number lookup match if mUseStrictPhoneNumberComparison is true. Bug: 7000177 Change-Id: I77e60117449cec6c37a9605ba4333a067d02a54c
* | Change fallback method for contact matchingYorke Lee2012-09-121-5/+21
|/ | | | | | | | | | | | Modified the fallback method that is used for contact matching whenever the original query fails to return a result. We previously performed a 7 digit match but this resulted in problems such as false positives when the area code is changed but the last 7 digits of a number are the same. The new fallback method uses the GB method of matching via the SQLite function phone_number_compare_loose. Bug: 7000177 Change-Id: I597b4b9e44ab2c4e4a5381832a3e9dfd0d51cf8f
* am 3b1b1d5e: am 7d112d54: Merge "Update HanziToPinyin table and tests."Makoto Onuki2012-08-241-93/+93
|\ | | | | | | | | * commit '3b1b1d5e732728ea7d60b408ab03f42e5d9ace8f': Update HanziToPinyin table and tests.
| * am 7d112d54: Merge "Update HanziToPinyin table and tests."Makoto Onuki2012-08-241-93/+93
| |\ | | | | | | | | | | | | * commit '7d112d54a173e6d6172aeeff5fa7dfee4abc2d73': Update HanziToPinyin table and tests.
| | * Update HanziToPinyin table and tests.Xiaotao Duan2012-08-241-93/+93
| | | | | | | | | | | | Change-Id: I160208ede00a4f63b257a0b6cc59ff5ad153960d
* | | Merge "Adding limit and offset parameters to calllog provider." into jb-mr1-devChiao Cheng2012-08-141-0/+60
|\ \ \
| * | | Adding limit and offset parameters to calllog provider.Chiao Cheng2012-08-031-0/+60
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Allow client to pass in limit and offset parameters in uri. Bug: 6849968 Change-Id: I535086449bfa76a5d8bc66567070141b76d19503
* | | | Merge "Don't leave stale normalized number when updating..." into jb-mr1-devMakoto Onuki2012-08-101-4/+49
|\ \ \ \
| * | | | Don't leave stale normalized number when updating...Makoto Onuki2012-08-101-4/+49
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | with invalid number. Also ContactsProvider2Test.testPhonesNormalizedNumber() should now work in non-us countries too. Bug 6960308 Change-Id: Ib15115f501ce67797dec8d05dc421f5931341b12
* | | | | resolved conflicts for merge of 3646b108 to jb-mr1-devJean-Baptiste Queru2012-08-101-0/+21156
|\ \ \ \ \ | |/ / / / |/| | / / | | |/ / | |/| | Change-Id: I2ca60f4e861128143bbfe7eb688b255432423a9d
| * | | am 28f87c6c: Merge "Sync HanziToPinyin tables with ICU 4.6."Jean-Baptiste Queru2012-08-101-0/+21156
| |\ \ \ | | | |/ | | |/| | | | | | | | | * commit '28f87c6cb3aedeb92c8e870de22b580e3e634da2': Sync HanziToPinyin tables with ICU 4.6.
| | * | Merge "Sync HanziToPinyin tables with ICU 4.6."Jean-Baptiste Queru2012-08-101-0/+21156
| | |\ \
| | | * | Sync HanziToPinyin tables with ICU 4.6.Xiaotao Duan2012-08-021-0/+21156
| | | | | | | | | | | | | | | | | | | | Change-Id: I6b6b144a460fbbf233222313559bbc546745d328
| | * | | Use telephony-common - DO NOT MERGEWink Saville2012-07-171-2/+2
| | | | | | | | | | | | | | | | | | | | Change-Id: I7eef631998e8e567f0e67c4e57d70aa5714aa90d
* | | | | [provider] Clean up unused code used to use for....Makoto Onuki2012-08-061-14/+0
| |_|_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | SEARCH_SUGGESTION_CLICKED and SEARCH_SUGGESTION_CREATE_CONTACT_CLICKED Bug 6909811 Change-Id: Icdf7cbb2e1f4c3e50939e9bde260cd341709ee34
* | | | Add missing size annotationsMakoto Onuki2012-07-232-0/+4
| | | | | | | | | | | | | | | | Change-Id: I465b87cec1508f5ca667570a2f1d05a8af2f6e2a
* | | | am d109b237: am ff91ec35: Tolerate crashes during re-aggregation.Makoto Onuki2012-07-201-0/+32
|\ \ \ \ | |/ / / | | | | | | | | | | | | * commit 'd109b23736e4171d23356642bd5dbe28743341da': Tolerate crashes during re-aggregation.
| * | | am ff91ec35: Tolerate crashes during re-aggregation.Makoto Onuki2012-07-191-0/+32
| |\ \ \ | | | | | | | | | | | | | | | | | | | | * commit 'ff91ec356f1b17dea095a880f61b8bc4ff333b1e': Tolerate crashes during re-aggregation.
| | * | | Tolerate crashes during re-aggregation.Makoto Onuki2012-07-181-0/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This CL consists of two parts: - Don't crash even if the name_lookup table contains malformed data. Just treat it as name-unmatch. - Don't crash even if an exception is thrown durign re-aggregation. Re-aggregation is not *that* important anyway, so in that case just bump the logic version and start the provider normally. (And even if we fail to bump the version number, just go ahead and continue.) Bug 6827136 Change-Id: Ifa3d4697c5d81f3480e0b8a9238b49312ac75e3b
* | | | | Merge commit 'e0c5d80d' into mitWink Saville2012-07-111-4/+4
|\ \ \ \ \ | |/ / / / | | | | | | | | | | | | | | | | | | | | | | | | | * commit 'e0c5d80d': Use telephony-common Change-Id: I56b4a75ac390e7710d3c3a9275a68c5dd6d20c2c
| * | | | Use telephony-commonWink Saville2012-07-061-2/+2
| | |/ / | |/| | | | | | | | | | Change-Id: I7eef631998e8e567f0e67c4e57d70aa5714aa90d
* | | | am 5a2cfba2: am 084a9d5e: Don\'t sort contacts supplied to global search app.Mathew Inwood2012-07-041-54/+2
|\ \ \ \ | |/ / / | | | | | | | | | | | | * commit '5a2cfba2623b8606ec5eb1a8e443957da2495e84': Don't sort contacts supplied to global search app.
| * | | am 084a9d5e: Don\'t sort contacts supplied to global search app.Mathew Inwood2012-07-041-54/+2
| |\ \ \ | | |/ / | | | | | | | | | | | | * commit '084a9d5ee564c758ff7709690ab404d6ac58e78d': Don't sort contacts supplied to global search app.
| | * | Don't sort contacts supplied to global search app.Mathew Inwood2012-07-041-54/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | They are to be sorted by the global search app itself instead. While we're at it, also remove 'create contact' and 'dial number' suggestions since they're not used. Change-Id: I0c56f638e347d101468e22d8fb2417552891eaa9
* | | | Reorganize import in contacts providerMakoto Onuki2012-06-2732-96/+80
| | | | | | | | | | | | | | | | Change-Id: If3afb134ea36bd93859efcd114885526e1592b91
* | | | Merge "Replace transparency with white for all pictures"Makoto Onuki2012-06-262-7/+54
|\ \ \ \
| * | | | Replace transparency with white for all picturesMakoto Onuki2012-06-252-7/+54
| |/ / / | | | | | | | | | | | | | | | | | | | | Bug 5261517 Change-Id: I6c16bb1f9897589beec222fc63ad899cd478b923
* | | | Fix transaction handling in the providerMakoto Onuki2012-06-253-3/+397
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixed issues that will happen when a batch operation for applyBatch() contain operations for both the contacts db and the profile db. - Make sure to set the right transaction listener when starting a transaction. There were cases where we started a transaction on the contacts db but passsing the profile provider as the listener, and vice versa. - Make sure transaction callbacks operate on the correct DB. There were cases where ContactsProvider2.onCommit() and its sbilings would operate on the profile DB, not on the contacts db. - Change the transaction finishing order. When we start transactions on both the contacts and the profile DB, we do so on the contacts db first, and then on the profile db. But when we clsoe them, we did it in the same order, which could potentially cause a deadlock. Now we close them in the reverse order; the profile db first, then the contacts db. - Remove mActiveDb. This wasn't set in switchTo{Profile,Contact}Mode(), but was lazily initialized. But I wasn't too sure if I always set the right db at the right timing. Looks like I forgot to do so in a few cases. Let's just remove it and always explicitly get the database from the current db helper. Bug 6250673 Change-Id: Idd18fc173596c973d0ff8b6e1b2456715c0f14f8
* | | am 4c3a0457: Support new query parameters introduced in Iaab5c38aMakoto Onuki2012-06-181-0/+35
|\ \ \ | |/ / | | | | | | | | | * commit '4c3a04572ead6ad9f0cfc20a34db3252fdb31201': Support new query parameters introduced in Iaab5c38a
| * | Support new query parameters introduced in Iaab5c38aMakoto Onuki2012-06-151-0/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | The new query parameters controls which field hone.CONTENT_FILTER_URI should search. Bug 6662259 Change-Id: I6f4cb4439dc4414cb96cf6a9fc66d0758ddf9faa
* | | am a499a2ad: Merge "Fix aggregation exception problem"Makoto Onuki2012-06-131-0/+50
|\ \ \ | |/ / |/| / | |/ | | * commit 'a499a2adb856223de65d298cd93d70c85afe3d4d': Fix aggregation exception problem
| * Fix aggregation exception problemTomas Mandorf2012-06-081-0/+50
| | | | | | | | | | | | | | | | This patch fixes a bug in the aggregation algorithm. When adding aggregation exceptions sometimes when excluding a raw contact from a Contact the contact information was not updated. Change-Id: If527c0fe0bd51eec77a71e466492691375889037
| * More aggressive fix for phone lookup issues.Dave Santoro2011-12-222-5/+85
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Rather than relying on a trailing suffix match on the longer of the two numbers (the one from caller ID and the one in the database), this first attempts to do the full internationalized-number-aware query that we'd normally do, and if no results are returned, falls back to a comparison of the trailing 7 digits of each number, as we did in Gingerbread. Also ports in Makoto's fix to the phone lookup tests. Bug: 5742389 Change-Id: Idda8474337bedaced59916c2b0af87b62b737d83
* | Handle blob in dumpCursorMakoto Onuki2012-05-091-2/+8
| | | | | | | | | | | | This is a test-only change. Change-Id: Ic4ed8cbae830809eb5938db78387fb969389ff2a
* | Merge "Don't show the invisible in frequent" into jb-devMakoto Onuki2012-05-013-6/+35
|\ \
| * | Don't show the invisible in frequentMakoto Onuki2012-04-303-6/+35
| | | | | | | | | | | | | | | | | | Bug 6000492 Change-Id: I5959cad0e3c04476a1b133508c60cdb8037b16f7
* | | Make names with special chars searchable.Makoto Onuki2012-04-301-7/+25
|/ / | | | | | | | | | | | | | | | | | | | | | | | | | | It's a better fix than I34bfa864, which was only a quick workaround for double barrelled names. Now names with other special characters are searchable too. Also, previously, a query "doublebarrelled" wouldn't match "double-barrelled", but now it will. Bug 5592553 Change-Id: Id1d44261f577df7abf701311ed1c86fb093547da
* | Don't suggest invisible for aggregationMakoto Onuki2012-04-251-6/+52
| | | | | | | | | | | | Bug 6400450 Change-Id: I4b5ed4a331f6740c3954b232633076e60e1de140
* | Merge "New aggregation logic"Makoto Onuki2012-04-233-27/+125
|\ \
| * | New aggregation logicMakoto Onuki2012-04-203-27/+125
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Now a raw contact can be merged into a contact containing raw contacts from the same account if there's at least one raw contact in those raw contacts that shares at least one email address, phone number, or identity. Now the aggregation logic version is 3. Also: - Make sure changes to the identity triggers aggregation. - Stop re-using some HashMaps/HashSets, as they don't shirink the internal table when clear()ed. During the aggregation update we may put a bunch of stuff into those, and we want to make sure that we don't keep unnecessarily bit internal tables after the upgrade. This should be okay with the modern dalvik GC. Change-Id: I855085d334679363cf9bffb918ca2ceb0cfe77f5
* | | Use 3 bucket sorting logic for frequent.Makoto Onuki2012-04-183-4/+183
| | | | | | | | | | | | | | | | | | Bug 6343819 Change-Id: Id2a2827fca611e62a5a1406faa73026625feaede
* | | Fix the last failing photo testMakoto Onuki2012-04-165-32/+118
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Also add some nice features to the asserts for complex data. - assertImageRawData() now writes the expected and actual images to the cache dir when failing. - assertStoredValues() and its siblings now dump the cursor to logcat when failing. Bug 6280711 Change-Id: I77aff61b0494580d0b2ba24b35eb045a18cd48c8
* | | Fix and simplify data usage feedbackMakoto Onuki2012-04-144-28/+305
| | | | | | | | | | | | | | | | | | | | | | | | | | | Now it correctly updates both raw_contacts and contacts too, with fewer sqls and less memory. Bug 6326418 Change-Id: I89f0f92bae5bad5505b218eca2a29ae56b51fe7f
* | | Use new URI for deleting usage statsMakoto Onuki2012-04-131-3/+3
| | | | | | | | | | | | | | | | | | Bug 5475575 Change-Id: I11894ef80727e2dc22e73330a5afca41c189135b
* | | Merge "New API to clear usage stats"Makoto Onuki2012-04-132-0/+41
|\ \ \
| * | | New API to clear usage statsMakoto Onuki2012-04-122-0/+41
| |/ / | | | | | | | | | | | | | | | | | | | | | resolver.delete(DataUsageFeedback.FEEDBACK_URI, null, null); Bug 5475575 Change-Id: I20adaea0350e95a8f8526507ddc1b2bdc8e8fe13
* | | Fix most of photo testsMakoto Onuki2012-04-125-45/+106
|/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Adjusting existing unit tests for higher res photos turned out to be tricky, because the size of the test images were selected for 256x256. (e.g. cropping tests) Also we don't want the display photo size to change depending on the running device. So let's just keep using 256x256 for all unit tests. Added new asserts to EvenMoreAssert to compare image raw data, which prints actual/expected dimensions when it fails. Even with this CL, ContactsProvider2Test.testInputStreamForPhoto() still fails with the following assert message. The image size seems to be correct, so I'm not sure why. This may be because we've changed the compression rate, but I didn't dig into it. "Different data lengths: expected=1088 actual=1578, expected dimentions=[96 x 96] actual dimentions=[96 x 96]" Anyway, with this CL at least PhotoStoreTest will no longer crash, so let's merge it now and take care of the failing test later. Change-Id: I935f76acee3c2de99030c62e14f43de07074fb8a