diff options
| author | Daisuke Miyakawa <dmiyakawa@google.com> | 2009-10-29 02:00:59 -0700 |
|---|---|---|
| committer | Android Git Automerger <android-git-automerger@android.com> | 2009-10-29 02:00:59 -0700 |
| commit | 636d5629c5a18c8fa37f63cd8468e12061b93328 (patch) | |
| tree | 921bc8ea2cbf1276a657e86c7225b0db758011f5 /tests | |
| parent | 11e3364a6afd4e83cc60894031793dabcc6193a3 (diff) | |
| parent | aa06a0e086d57ad3a0d063dfb5ab2cfb7936e4b4 (diff) | |
| download | frameworks_base-636d5629c5a18c8fa37f63cd8468e12061b93328.zip frameworks_base-636d5629c5a18c8fa37f63cd8468e12061b93328.tar.gz frameworks_base-636d5629c5a18c8fa37f63cd8468e12061b93328.tar.bz2 | |
am aa06a0e0: am 3c828e24: Merge change I9195a354 into eclair-mr2
Merge commit 'aa06a0e086d57ad3a0d063dfb5ab2cfb7936e4b4'
* commit 'aa06a0e086d57ad3a0d063dfb5ab2cfb7936e4b4':
Add partial support of Android-specific properties.
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/AndroidTests/src/com/android/unit_tests/vcard/VCardExporterTests.java | 22 |
1 files changed, 19 insertions, 3 deletions
diff --git a/tests/AndroidTests/src/com/android/unit_tests/vcard/VCardExporterTests.java b/tests/AndroidTests/src/com/android/unit_tests/vcard/VCardExporterTests.java index d0097c4..f1a46d6 100644 --- a/tests/AndroidTests/src/com/android/unit_tests/vcard/VCardExporterTests.java +++ b/tests/AndroidTests/src/com/android/unit_tests/vcard/VCardExporterTests.java @@ -643,9 +643,6 @@ public class VCardExporterTests extends AndroidTestCase { testStructuredNameUseSuperPrimaryCommon(V30); } - /** - * There's no property for nickname in vCard 2.1, so we don't have any requirement on it. - */ public void testNickNameV30() { ExportTestResolver resolver = new ExportTestResolver(); ContentValues contentValues = resolver.buildData(Nickname.CONTENT_ITEM_TYPE); @@ -1269,4 +1266,23 @@ public class VCardExporterTests extends AndroidTestCase { verifyOneComposition(resolver, handler, version); } + + /** + * There's no "NICKNAME" property in vCard 2.1, while there is in vCard 3.0. + * We use Android-specific "X-ANDROID-CUSTOM" property. + * This test verifies the functionality. + */ + public void testNickNameV21() { + ExportTestResolver resolver = new ExportTestResolver(); + ContentValues contentValues = resolver.buildData(Nickname.CONTENT_ITEM_TYPE); + contentValues.put(Nickname.NAME, "Nicky"); + + VCardVerificationHandler handler = new VCardVerificationHandler(this, V21); + handler.addNewVerifierWithEmptyName() + .addNodeWithOrder("X-ANDROID-CUSTOM", Nickname.CONTENT_ITEM_TYPE + ";Nicky"); + + // TODO: also test import part. + + verifyOneComposition(resolver, handler, V21); + } } |
