diff options
Diffstat (limited to 'source4/dsdb/tests/python/sort.py')
| -rw-r--r-- | source4/dsdb/tests/python/sort.py | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/source4/dsdb/tests/python/sort.py b/source4/dsdb/tests/python/sort.py index c4d2c445268..b7b9d836e8f 100644 --- a/source4/dsdb/tests/python/sort.py +++ b/source4/dsdb/tests/python/sort.py @@ -5,7 +5,6 @@ from unicodedata import normalize import locale locale.setlocale(locale.LC_ALL, ('en_US', 'UTF-8')) -from collections import Counter import optparse import sys import os @@ -191,7 +190,13 @@ class BaseSortTests(samba.tests.TestCase): self.expected_results[k] = (fixed, list(reversed(fixed))) for k in ('streetAddress', 'postalAddress'): if k in self.expected_results: - c = Counter([u[k] for u in self.users]) + c = {} + for u in self.users: + x = u[k] + if x in c: + c[x] += 1 + continue + c[x] = 1 fixed = [] for x in FIENDISH_TESTS: fixed += [norm(x)] * c[x] |
