[web] Prevent errors from silently resolving and simplify promises in tests (#28621)

GitOrigin-RevId: e6ba7d25436c1350f8eef74df34dce03f93af909
This commit is contained in:
Antoine Clausse
2025-09-26 10:12:01 +02:00
committed by Copybot
parent 3bba9c9fb7
commit 1b8a183430

View File

@@ -492,16 +492,13 @@ function receiveFileDelete() {
function receiveFileDeleteById() {
beforeEach(async function (ctx) {
await new Promise(resolve => {
ctx.TpdsUpdateHandler.deleteUpdate(
ctx.userId,
ctx.projectId,
'', // projectName
ctx.path,
ctx.source,
resolve
)
})
await ctx.TpdsUpdateHandler.promises.deleteUpdate(
ctx.userId,
ctx.projectId,
'', // projectName
ctx.path,
ctx.source
)
})
}