Bug #1541863: uuid.uuid1 failed to generate unique identifiers

on systems with low clock resolution.
This commit is contained in:
Martin v. Löwis 2006-08-18 03:47:18 +00:00
parent 59e9ac8ebe
commit 2eb8c4f292
3 changed files with 14 additions and 3 deletions

View file

@ -429,7 +429,7 @@ class TestUUID(TestCase):
# Make sure the generated UUIDs are actually unique.
uuids = {}
for u in [uuid.uuid1() for i in range(1000)]:
for u in [uuid.uuid4() for i in range(1000)]:
uuids[u] = 1
equal(len(uuids.keys()), 1000)