fix: improve flaky federation test (#15845)

This commit is contained in:
anatawa12 2025-04-16 07:51:21 +09:00 committed by GitHub
parent de19d9a4d4
commit 86774ad753
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -381,7 +381,8 @@ describe('User', () => {
await alice.client.request('i/delete-account', { password: alice.password }); await alice.client.request('i/delete-account', { password: alice.password });
// NOTE: user deletion query is slow // NOTE: user deletion query is slow
await sleep(4000); // FIXME: ensure user is removed successfully
await sleep(10000);
const following = await bob.client.request('users/following', { userId: bob.id }); const following = await bob.client.request('users/following', { userId: bob.id });
strictEqual(following.length, 0); // no following relation strictEqual(following.length, 0); // no following relation
@ -480,7 +481,8 @@ describe('User', () => {
await aAdmin.client.request('admin/suspend-user', { userId: alice.id }); await aAdmin.client.request('admin/suspend-user', { userId: alice.id });
// NOTE: user deletion query is slow // NOTE: user deletion query is slow
await sleep(4000); // FIXME: ensure user is removed successfully
await sleep(10000);
const following = await bob.client.request('users/following', { userId: bob.id }); const following = await bob.client.request('users/following', { userId: bob.id });
strictEqual(following.length, 0); // no following relation strictEqual(following.length, 0); // no following relation