Skip to content

Commit

Permalink
Bug 1655193 [wpt PR 24746] - Updating the putAll implementation to re…
Browse files Browse the repository at this point in the history
…turn one request., a=testonly

Automatic update from web-platform-tests
Updating the putAll implementation to return one request.

This change updates the existing putAll implementation to match
the explainer more. It does not yet support the put-all-or-none
behavior, but it does only return one request now.

Design Doc:
https://docs.google.com/document/d/1wawQ8Pl-Vi6GQN5-y2UVkcghipcOGg0WRAC0ZyBkezg/edit#

Bug: https://bugs.chromium.org/p/chromium/issues/detail?id=1087927

Change-Id: I2c5e9d2d71801eaab3c1c9e94a3968afb8d109b2
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2310110
Commit-Queue: Numfor Mbiziwo-tiapo <numsgoogle.com>
Commit-Queue: Daniel Murphy <dmurphchromium.org>
Reviewed-by: Daniel Murphy <dmurphchromium.org>
Reviewed-by: Olivier Yiptong <oyiptongchromium.org>
Cr-Commit-Position: refs/heads/master{#793656}

--

wpt-commits: 18b9e70e4a3c3cc30cd05f34bff9093b0313b93e
wpt-pr: 24746

UltraBlame original commit: 04f08e6991664d3bc9604396fa82117e04ecf223
  • Loading branch information
marco-c committed Aug 16, 2020
1 parent a963eed commit 468106b
Showing 1 changed file with 48 additions and 24 deletions.
Expand Up @@ -25,6 +25,38 @@ testCase
db
)
;
}
)
;
const
txn
=
db
.
transaction
(
[
'
books
'
]
'
readwrite
'
)
;
const
objectStore
=
txn
.
objectStore
(
'
books
'
)
;
let
values
=
Expand Down Expand Up @@ -67,40 +99,32 @@ title3
}
]
;
const
putAllRequests
let
putAllRequest
=
store
objectStore
.
putAll
(
values
)
;
putAllRequests
.
forEach
(
async
request
=
>
{
await
promiseForRequest
(
testCase
request
)
;
}
putAllRequest
)
;
}
await
promiseForTransaction
(
testCase
txn
)
;
const
txn
txn2
=
db
.
Expand All @@ -117,9 +141,9 @@ readonly
)
;
const
objectStore
objectStore2
=
txn
txn2
.
objectStore
(
Expand All @@ -131,7 +155,7 @@ books
const
getRequest1
=
objectStore
objectStore2
.
get
(
Expand All @@ -143,7 +167,7 @@ one
const
getRequest2
=
objectStore
objectStore2
.
get
(
Expand All @@ -155,7 +179,7 @@ two
const
getRequest3
=
objectStore
objectStore2
.
get
(
Expand All @@ -168,7 +192,7 @@ await
promiseForTransaction
(
testCase
txn
txn2
)
;
assert_array_equals
Expand Down

0 comments on commit 468106b

Please sign in to comment.