Remove string.lowercase usage

Python 3 has no `lowercase` in string module, so we should use
`ascii_lowercase` instead of it.

Related to blueprint make-python3-compatible

Change-Id: I8407db72fc37c14d189698c1d51b1d9b45769760
This commit is contained in:
Victor Sergeyev 2013-12-20 12:00:41 +02:00
parent 8d3b5a0b2d
commit 47083eb909
1 changed files with 2 additions and 1 deletions

View File

@ -35,7 +35,8 @@ def _gen_credentials(*names):
"""Generate credentials."""
auth_dict = {}
for name in names:
val = ''.join(random.choice(string.lowercase) for i in moves.range(10))
val = ''.join(random.choice(string.ascii_lowercase)
for i in moves.range(10))
auth_dict[name] = val
return auth_dict