chore(tests): avoid delaying when inserting every post in tests (#625)
This commit is contained in:
parent
8dd9f00135
commit
6bb4c80450
|
@ -45,7 +45,11 @@ export async function restoreMastodonData () {
|
|||
console.log('Restoring mastodon data...')
|
||||
let internalIdsToIds = {}
|
||||
for (let action of actions) {
|
||||
await new Promise(resolve => setTimeout(resolve, 1000)) // delay so that notifications have proper order
|
||||
if (!action.post) {
|
||||
// If the action is a boost, favorite, etc., then it needs to
|
||||
// be delayed, otherwise it may appear in an unpredictable order and break the tests.
|
||||
await new Promise(resolve => setTimeout(resolve, 1000))
|
||||
}
|
||||
console.log(JSON.stringify(action))
|
||||
let accessToken = users[action.user].accessToken
|
||||
|
||||
|
|
Loading…
Reference in a new issue