def dstore(self, request, store, secret_key): if request.param == 'hash': return HashDecorator(store) elif request.param == 'uuid': return self.ustore(store) elif request.param == 'hmac': return HMACDecorator(secret_key, store) elif request.param == 'prefix': return PrefixDecorator('SaMpLe_PrEfIX', store)
def test_copy_raises_not_implemented(self, store): with pytest.raises(NotImplementedError): HMACDecorator(b'secret', store).copy(u'src', u'dest')
def setUp(self): self.store = HMACDecorator('my_secret_key', DictStore())
def hmacstore(self, secret_key, store): return HMACDecorator(secret_key, store)