From cb039b3e7e8a3a260edc80b0de79fc27af795cf0 Mon Sep 17 00:00:00 2001 From: zsloan Date: Thu, 18 Feb 2021 21:58:58 +0000 Subject: Fixed TestCheckResourceAvailability to make it work after realizing that Redis.smembers apparently returns values as bytes --- wqflask/tests/unit/utility/test_authentication_tools.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'wqflask/tests/unit/utility') diff --git a/wqflask/tests/unit/utility/test_authentication_tools.py b/wqflask/tests/unit/utility/test_authentication_tools.py index 6d817f5e..fff5fd8f 100644 --- a/wqflask/tests/unit/utility/test_authentication_tools.py +++ b/wqflask/tests/unit/utility/test_authentication_tools.py @@ -89,7 +89,7 @@ class TestCheckResourceAvailability(unittest.TestCase): requests_mock): """Test the resource availability if the user is the super user""" resource_id_mock.return_value = 1 - redis_mock.smembers.return_value = ["Jane"] + redis_mock.smembers.return_value = [b"Jane"] add_new_resource_mock.return_value = {"default_mask": 2} requests_mock.return_value = TestResponse() test_dataset = mock.MagicMock() -- cgit v1.2.3