From c089668e6ebb92c6d813ce731ea3b676e0024b7a Mon Sep 17 00:00:00 2001 From: Jonathan Wright <8390543+jonathanspw@users.noreply.github.com> Date: Wed, 3 May 2023 14:47:11 -0500 Subject: [PATCH] Update test_memcached.py (#228) Fix CI per https://github.com/bbangert/beaker/pull/227#issuecomment-1532664771 --- tests/test_memcached.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/test_memcached.py b/tests/test_memcached.py index b1bee6b..74f942d 100644 --- a/tests/test_memcached.py +++ b/tests/test_memcached.py @@ -291,9 +291,9 @@ def test_uses_pylibmc_client(self): def test_dont_use_pylibmc_client(self): from beaker.ext.memcached import _load_client - load_mock = mock.Mock() + load_mock = unittest.mock.Mock() load_mock.return_value = _load_client('memcache') - with mock.patch('beaker.ext.memcached._load_client', load_mock): + with unittest.mock.patch('beaker.ext.memcached._load_client', load_mock): cache = Cache('test', data_dir='./cache', url=mc_url, type="ext:memcached") assert not isinstance(cache.namespace, memcached.PyLibMCNamespaceManager) assert isinstance(cache.namespace, memcached.MemcachedNamespaceManager)