| OLD | NEW |
| 1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
| 2 <!-- This is in chromium/ because the equivalent version available in Web |
| 3 Platform Tests also asserts the presence of the Client's `type` attribute. |
| 4 This less precise version (and its resources) should be maintained only to |
| 5 preserve test coverage until the attribute is implemented. See |
| 6 https://crbug.com/705685 --> |
| 2 <title>Service Worker: Clients.matchAll</title> | 7 <title>Service Worker: Clients.matchAll</title> |
| 3 <script src="../resources/testharness.js"></script> | 8 <script src="../../resources/testharness.js"></script> |
| 4 <script src="../resources/testharnessreport.js"></script> | 9 <script src="../../resources/testharnessreport.js"></script> |
| 5 <script src="resources/test-helpers.js"></script> | 10 <script src="../resources/test-helpers.js"></script> |
| 6 <script> | 11 <script> |
| 7 var scope = 'resources/blank.html?clients-matchAll'; | 12 var scope = 'resources/blank.html?clients-matchAll'; |
| 8 var expectedFirst = [ | 13 var expectedFirst = [ |
| 9 /* visibilityState, focused, url, frameType */ | 14 /* visibilityState, focused, url, frameType */ |
| 10 ['visible', true, new URL(scope + '#1', location).toString(), 'nested'], | 15 ['visible', true, new URL(scope + '#1', location).toString(), 'nested'], |
| 11 ['visible', false, new URL(scope + '#2', location).toString(), 'nested'] | 16 ['visible', false, new URL(scope + '#2', location).toString(), 'nested'] |
| 12 ]; | 17 ]; |
| 13 var expectedSecond = [ | 18 var expectedSecond = [ |
| 14 /* visibilityState, focused, url, frameType */ | 19 /* visibilityState, focused, url, frameType */ |
| 15 ['visible', true, new URL(scope + '#2', location).toString(), 'nested'], | 20 ['visible', true, new URL(scope + '#2', location).toString(), 'nested'], |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 53 .then(function(message) { | 58 .then(function(message) { |
| 54 assert_equals(message.data.length, 2); | 59 assert_equals(message.data.length, 2); |
| 55 assert_array_equals(message.data[0], expectedSecond[0]); | 60 assert_array_equals(message.data[0], expectedSecond[0]); |
| 56 assert_array_equals(message.data[1], expectedSecond[1]); | 61 assert_array_equals(message.data[1], expectedSecond[1]); |
| 57 frame1.remove(); | 62 frame1.remove(); |
| 58 frame2.remove(); | 63 frame2.remove(); |
| 59 return service_worker_unregister_and_done(t, scope); | 64 return service_worker_unregister_and_done(t, scope); |
| 60 }) | 65 }) |
| 61 }, 'Test Clients.matchAll()'); | 66 }, 'Test Clients.matchAll()'); |
| 62 </script> | 67 </script> |
| OLD | NEW |