mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-08-15 07:18:58 -04:00
Use redis_client rather than wrapper method
Fixes a bug where we were calling a wrapper method when instead we should have been calling the redis_client. This had resulted in no actual calls to redis happening.
This commit is contained in:
@@ -482,9 +482,9 @@ def test_deletes_caches_when_modifying_templates(
|
||||
|
||||
|
||||
def test_deletes_cached_users_when_archiving_service(mocker):
|
||||
mock_redis_delete = mocker.patch('app.notify_client.service_api_client.cache.delete')
|
||||
mock_redis_delete = mocker.patch('app.notify_client.service_api_client.redis_client.delete')
|
||||
mocker.patch('notifications_python_client.base.BaseAPIClient.request')
|
||||
|
||||
service_api_client.archive_service(SERVICE_ONE_ID, ["my-user-id1", "my-user-id2"])
|
||||
|
||||
assert mock_redis_delete.call_args_list == [call('user-my-user-id1', 'user-my-user-id2')]
|
||||
assert call('user-my-user-id1', 'user-my-user-id2') in mock_redis_delete.call_args_list
|
||||
|
||||
Reference in New Issue
Block a user