For sake of future python3 encode FakeMemcache hashes
For Python3.x this change would be required, but the API tests don't yet run under Python3. Change-Id: I026dc4625aa09108b75d40d751d7ee8c766c4caa
This commit is contained in:
parent
41d2cc9bf2
commit
816cef8af7
@ -34,8 +34,8 @@ VALID_TOKEN2 = '4562138218392832'
|
||||
|
||||
class FakeMemcache(object):
|
||||
|
||||
TOKEN_HASH = hashlib.sha256(VALID_TOKEN).hexdigest()
|
||||
TOKEN2_HASH = hashlib.sha256(VALID_TOKEN2).hexdigest()
|
||||
TOKEN_HASH = hashlib.sha256(VALID_TOKEN.encode('utf-8')).hexdigest()
|
||||
TOKEN2_HASH = hashlib.sha256(VALID_TOKEN2.encode('utf-8')).hexdigest()
|
||||
|
||||
def get(self, key):
|
||||
if (key == "tokens/%s" % VALID_TOKEN or
|
||||
|
Loading…
x
Reference in New Issue
Block a user