diff options
author | Patrick Ohly <patrick.ohly@intel.com> | 2013-03-26 15:29:20 +0100 |
---|---|---|
committer | Patrick Ohly <patrick.ohly@intel.com> | 2013-05-06 16:28:12 +0200 |
commit | be4b2393cdb46dc4d55798a29fb442667a783553 (patch) | |
tree | 11248023b25795624b37cb9b93efe21c65c572ed | |
parent | 48b577370f30ceabaf4636d804a037769588f7f2 (diff) |
PIM testing: allow more than 1000 contacts in testActive
The sorting got broken when the number of contacts exceeds the 3
digits reserved via the 03d formatting specifier. Now allow four
digits = up to 9999 contacts.
-rwxr-xr-x | src/dbus/server/pim/testpim.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/dbus/server/pim/testpim.py b/src/dbus/server/pim/testpim.py index 270a82da..de7aac73 100755 --- a/src/dbus/server/pim/testpim.py +++ b/src/dbus/server/pim/testpim.py @@ -1669,8 +1669,8 @@ END:VCARD''' output = open(item, "w") output.write('''BEGIN:VCARD VERSION:3.0 -FN:John_%(peer)s%(index)03d Doe -N:Doe;John_%(peer)s%(index)03d +FN:John_%(peer)s%(index)04d Doe +N:Doe;John_%(peer)s%(index)04d END:VCARD''' % {'peer': peer, 'index': index}) output.close() @@ -1705,7 +1705,7 @@ END:VCARD''' % {'peer': peer, 'index': index}) del contact['source'] expected = [{'full-name': first + ' Doe', 'structured-name': {'given': first, 'family': 'Doe'}} for \ - first in ['John_%(peer)s%(index)03d' % {'peer': peer, + first in ['John_%(peer)s%(index)04d' % {'peer': peer, 'index': index} \ for peer in active \ for index in range(0, contactsPerPeer)] ] |