aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorGravatar wookie184 <[email protected]>2024-06-13 15:14:21 +0100
committerGravatar GitHub <[email protected]>2024-06-13 15:14:21 +0100
commit961f5aa2f26f46032def9808f3f1bfb894959ae9 (patch)
tree280caceab6050e7689e14710690fd4da3670f719 /tests
parentFix site startup command used in docker-compose.yml (#3093) (diff)
parentMerge branch 'main' into use-itertools-batched (diff)
Merge pull request #3090 from python-discord/use-itertools-batched
Use new `itertools.batched` instead of `more_itertools.chunked`
Diffstat (limited to 'tests')
-rw-r--r--tests/bot/exts/backend/sync/test_users.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/bot/exts/backend/sync/test_users.py b/tests/bot/exts/backend/sync/test_users.py
index 2fc000446..26bf0d9a0 100644
--- a/tests/bot/exts/backend/sync/test_users.py
+++ b/tests/bot/exts/backend/sync/test_users.py
@@ -210,8 +210,8 @@ class UserSyncerSyncTests(unittest.IsolatedAsyncioTestCase):
diff = _Diff(self.users, [], None)
await UserSyncer._sync(diff)
- self.bot.api_client.post.assert_any_call("bot/users", json=diff.created[:self.chunk_size])
- self.bot.api_client.post.assert_any_call("bot/users", json=diff.created[self.chunk_size:])
+ self.bot.api_client.post.assert_any_call("bot/users", json=tuple(diff.created[:self.chunk_size]))
+ self.bot.api_client.post.assert_any_call("bot/users", json=tuple(diff.created[self.chunk_size:]))
self.assertEqual(self.bot.api_client.post.call_count, self.chunk_count)
self.bot.api_client.put.assert_not_called()
@@ -222,8 +222,8 @@ class UserSyncerSyncTests(unittest.IsolatedAsyncioTestCase):
diff = _Diff([], self.users, None)
await UserSyncer._sync(diff)
- self.bot.api_client.patch.assert_any_call("bot/users/bulk_patch", json=diff.updated[:self.chunk_size])
- self.bot.api_client.patch.assert_any_call("bot/users/bulk_patch", json=diff.updated[self.chunk_size:])
+ self.bot.api_client.patch.assert_any_call("bot/users/bulk_patch", json=tuple(diff.updated[:self.chunk_size]))
+ self.bot.api_client.patch.assert_any_call("bot/users/bulk_patch", json=tuple(diff.updated[self.chunk_size:]))
self.assertEqual(self.bot.api_client.patch.call_count, self.chunk_count)
self.bot.api_client.post.assert_not_called()