Looks pretty good, one more idea... Is it possible to add a test where you ...
4 years, 10 months ago
(2015-06-10 03:50:24 UTC)
#3
Looks pretty good, one more idea...
Is it possible to add a test where you register some things in origin A, and
some things in origin B, then verify that getRegistrations() from A returns only
things in A?
I think you can use the get_host_info() function in resources/get-host-info.js
to create a layout test that spans different origins. An iframe using
HTTP_ORIGIN and an iframe using HTTP_REMOTE_ORIGIN will be different origins.
https://codereview.chromium.org/1168393002/diff/20001/LayoutTests/http/tests/...
File LayoutTests/http/tests/serviceworker/getregistrations.html (right):
https://codereview.chromium.org/1168393002/diff/20001/LayoutTests/http/tests/...
LayoutTests/http/tests/serviceworker/getregistrations.html:1: <!DOCTYPE html>
Should add a <title>
https://codereview.chromium.org/1168393002/diff/20001/LayoutTests/http/tests/...
LayoutTests/http/tests/serviceworker/getregistrations.html:55:
service_worker_unregister(t, scope2);
I think the unregister promises should be returned, or else this test will
finish before registration occurred. You might use Promise.all or do a
return->then->return.
jungkees
Sure. I'll add a test about checking whether it gets the registrations only for the ...
4 years, 10 months ago
(2015-06-10 04:53:54 UTC)
#4
Sure. I'll add a test about checking whether it gets the registrations only for
the same origin. Thanks for the pointers.
jungkees
Patchset #3 (id:40001) has been deleted
4 years, 10 months ago
(2015-06-11 12:26:58 UTC)
#5
Patchset #3 (id:40001) has been deleted
jungkees
A new snapshot has been uploaded having addressed the comments and added a test to ...
4 years, 10 months ago
(2015-06-11 12:43:41 UTC)
#6
A new snapshot has been uploaded having addressed the comments and added a test
to check if it returns only the same origin registrations. PTAL
jungkees
Added a missing unregister call in getregistrations.html.
4 years, 10 months ago
(2015-06-11 15:02:54 UTC)
#7
Added a missing unregister call in getregistrations.html.
Issue 1168393002: Service Worker: Add ServiceWorkerContainer.getRegistrations() method. (Blink layout tests)
(Closed)
Created 4 years, 10 months ago by jungkees
Modified 4 years, 10 months ago
Reviewers: falken, kinuko, nhiroki, xiang, tkent
Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Comments: 9