mirror of
https://github.com/servo/servo.git
synced 2025-08-07 14:35:33 +01:00
Auto merge of #26317 - gterzian:fix_job_queue, r=asajeffrey
ServiceWorker: restructure Job Queue, Register flow, to better match spec <!-- Please describe your changes on the following line: --> --- <!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: --> - [ ] `./mach build -d` does not report any errors - [ ] `./mach test-tidy` does not report any errors - [ ] These changes fix #26108 (GitHub issue number if applicable) <!-- Either: --> - [ ] There are tests for these changes OR - [ ] These changes do not require tests because ___ <!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.--> <!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->
This commit is contained in:
commit
b22e34fb74
21 changed files with 887 additions and 637 deletions
|
@ -1,7 +1,19 @@
|
|||
[service-worker-registration.https.html]
|
||||
[Test: Asserts Installing Service Worker and its Registration]
|
||||
expected: FAIL
|
||||
|
||||
[Test: Installing Service Worker ScriptURL property]
|
||||
expected: FAIL
|
||||
|
||||
[Test: Throws Error when Invalid Scope]
|
||||
expected: FAIL
|
||||
|
||||
[Test: Asserts Active Service Worker and its Registration]
|
||||
expected: FAIL
|
||||
|
||||
[Test: Active Service Worker ScriptURL property]
|
||||
expected: FAIL
|
||||
|
||||
[Test: Asserts ServiceWorkerContainer in Navigator]
|
||||
expected: FAIL
|
||||
|
||||
|
|
|
@ -14305,7 +14305,7 @@
|
|||
],
|
||||
"service-workers": {
|
||||
"service-worker-registration.https.html": [
|
||||
"949992e45de6858c336936b4f1ea4bca76db1d91",
|
||||
"04d74fb5c582a3fef8dc589868f0b8c3e402eab2",
|
||||
[
|
||||
null,
|
||||
{}
|
||||
|
|
|
@ -0,0 +1,6 @@
|
|||
[service-worker-registration.https.html]
|
||||
type: testharness
|
||||
[Test: Asserts Active Service Worker and its Registration]
|
||||
expected: FAIL
|
||||
[Test: Active Service Worker ScriptURL property]
|
||||
expected: FAIL
|
|
@ -20,6 +20,12 @@ promise_test(function() {
|
|||
});
|
||||
}, "Test: Active Service Worker ScriptURL property");
|
||||
|
||||
promise_test(function() {
|
||||
return register_sw('resources/sw.js').then(function(sw_reg) {
|
||||
assert_equals(sw_reg.installing.scriptURL, location.href.replace("service-worker-registration.https.html", "resources/sw.js"));
|
||||
});
|
||||
}, "Test: Installing Service Worker ScriptURL property");
|
||||
|
||||
promise_test(function() {
|
||||
return register_sw('sw.js').then(function(sw_reg) {
|
||||
assert_class_string(sw_reg, "ServiceWorkerRegistration");
|
||||
|
@ -28,6 +34,13 @@ promise_test(function() {
|
|||
});
|
||||
}, "Test: Asserts Active Service Worker and its Registration");
|
||||
|
||||
promise_test(function() {
|
||||
return register_sw('sw.js').then(function(sw_reg) {
|
||||
assert_class_string(sw_reg, "ServiceWorkerRegistration");
|
||||
assert_class_string(sw_reg.installing, "ServiceWorker");
|
||||
});
|
||||
}, "Test: Asserts Installing Service Worker and its Registration");
|
||||
|
||||
promise_test(function() {
|
||||
return register_sw('resources/sw.js', './').then(function(sw_reg) {
|
||||
assert_equals(sw_reg.scope, location.href.replace("service-worker-registration.https.html", ""));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue