From 36d22d82aa202bb199967e9512281e9a53db42c9 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 7 Apr 2024 21:33:14 +0200 Subject: Adding upstream version 115.7.0esr. Signed-off-by: Daniel Baumann --- .../web-platform/tests/geolocation-API/META.yml | 4 + .../geolocation-API/PositionOptions.https.html | 93 ++++++++++++++++++ .../clearWatch_TypeError.https.html | 13 +++ .../disabled-by-permissions-policy.https.sub.html | 70 ++++++++++++++ ...ed-by-permissions-policy.https.sub.html.headers | 1 + ...olicy-attribute-redirect-on-load.https.sub.html | 36 +++++++ ...d-by-permission-policy-attribute.https.sub.html | 34 +++++++ .../enabled-by-permissions-policy.https.sub.html | 45 +++++++++ ...ed-by-permissions-policy.https.sub.html.headers | 1 + ...elf-origin-by-permissions-policy.https.sub.html | 42 ++++++++ ...in-by-permissions-policy.https.sub.html.headers | 1 + .../getCurrentPosition_TypeError.https.html | 61 ++++++++++++ .../getCurrentPosition_permission_allow.https.html | 55 +++++++++++ .../getCurrentPosition_permission_deny.https.html | 29 ++++++ .../geolocation-API/idlharness.https.window.js | 14 +++ .../geolocation-API/non-fully-active.https.html | 106 +++++++++++++++++++++ .../geolocation-API/non-secure-contexts.http.html | 82 ++++++++++++++++ .../tests/geolocation-API/permission.https.html | 14 +++ .../tests/geolocation-API/resources/iframe.html | 3 + .../web-platform/tests/geolocation-API/support.js | 30 ++++++ .../watchPosition_TypeError.https.html | 65 +++++++++++++ .../watchPosition_permission_deny.https.html | 45 +++++++++ 22 files changed, 844 insertions(+) create mode 100644 testing/web-platform/tests/geolocation-API/META.yml create mode 100644 testing/web-platform/tests/geolocation-API/PositionOptions.https.html create mode 100644 testing/web-platform/tests/geolocation-API/clearWatch_TypeError.https.html create mode 100644 testing/web-platform/tests/geolocation-API/disabled-by-permissions-policy.https.sub.html create mode 100644 testing/web-platform/tests/geolocation-API/disabled-by-permissions-policy.https.sub.html.headers create mode 100644 testing/web-platform/tests/geolocation-API/enabled-by-permission-policy-attribute-redirect-on-load.https.sub.html create mode 100644 testing/web-platform/tests/geolocation-API/enabled-by-permission-policy-attribute.https.sub.html create mode 100644 testing/web-platform/tests/geolocation-API/enabled-by-permissions-policy.https.sub.html create mode 100644 testing/web-platform/tests/geolocation-API/enabled-by-permissions-policy.https.sub.html.headers create mode 100644 testing/web-platform/tests/geolocation-API/enabled-on-self-origin-by-permissions-policy.https.sub.html create mode 100644 testing/web-platform/tests/geolocation-API/enabled-on-self-origin-by-permissions-policy.https.sub.html.headers create mode 100644 testing/web-platform/tests/geolocation-API/getCurrentPosition_TypeError.https.html create mode 100644 testing/web-platform/tests/geolocation-API/getCurrentPosition_permission_allow.https.html create mode 100644 testing/web-platform/tests/geolocation-API/getCurrentPosition_permission_deny.https.html create mode 100644 testing/web-platform/tests/geolocation-API/idlharness.https.window.js create mode 100644 testing/web-platform/tests/geolocation-API/non-fully-active.https.html create mode 100644 testing/web-platform/tests/geolocation-API/non-secure-contexts.http.html create mode 100644 testing/web-platform/tests/geolocation-API/permission.https.html create mode 100644 testing/web-platform/tests/geolocation-API/resources/iframe.html create mode 100644 testing/web-platform/tests/geolocation-API/support.js create mode 100644 testing/web-platform/tests/geolocation-API/watchPosition_TypeError.https.html create mode 100644 testing/web-platform/tests/geolocation-API/watchPosition_permission_deny.https.html (limited to 'testing/web-platform/tests/geolocation-API') diff --git a/testing/web-platform/tests/geolocation-API/META.yml b/testing/web-platform/tests/geolocation-API/META.yml new file mode 100644 index 0000000000..e3d6c4dff8 --- /dev/null +++ b/testing/web-platform/tests/geolocation-API/META.yml @@ -0,0 +1,4 @@ +spec: https://w3c.github.io/geolocation-api/ +suggested_reviewers: + - marcoscaceres + - reillyeon diff --git a/testing/web-platform/tests/geolocation-API/PositionOptions.https.html b/testing/web-platform/tests/geolocation-API/PositionOptions.https.html new file mode 100644 index 0000000000..6b36d66d73 --- /dev/null +++ b/testing/web-platform/tests/geolocation-API/PositionOptions.https.html @@ -0,0 +1,93 @@ + + +Geolocation Test: PositionOptions tests + + + + + + + diff --git a/testing/web-platform/tests/geolocation-API/clearWatch_TypeError.https.html b/testing/web-platform/tests/geolocation-API/clearWatch_TypeError.https.html new file mode 100644 index 0000000000..37ebeca885 --- /dev/null +++ b/testing/web-platform/tests/geolocation-API/clearWatch_TypeError.https.html @@ -0,0 +1,13 @@ + + +Geolocation Test: clearWatch TypeError tests + + + + diff --git a/testing/web-platform/tests/geolocation-API/disabled-by-permissions-policy.https.sub.html b/testing/web-platform/tests/geolocation-API/disabled-by-permissions-policy.https.sub.html new file mode 100644 index 0000000000..6bd3e3500b --- /dev/null +++ b/testing/web-platform/tests/geolocation-API/disabled-by-permissions-policy.https.sub.html @@ -0,0 +1,70 @@ + + + + + + + + + + diff --git a/testing/web-platform/tests/geolocation-API/disabled-by-permissions-policy.https.sub.html.headers b/testing/web-platform/tests/geolocation-API/disabled-by-permissions-policy.https.sub.html.headers new file mode 100644 index 0000000000..26bfbc2496 --- /dev/null +++ b/testing/web-platform/tests/geolocation-API/disabled-by-permissions-policy.https.sub.html.headers @@ -0,0 +1 @@ +Permissions-Policy: geolocation=() diff --git a/testing/web-platform/tests/geolocation-API/enabled-by-permission-policy-attribute-redirect-on-load.https.sub.html b/testing/web-platform/tests/geolocation-API/enabled-by-permission-policy-attribute-redirect-on-load.https.sub.html new file mode 100644 index 0000000000..864fb5e761 --- /dev/null +++ b/testing/web-platform/tests/geolocation-API/enabled-by-permission-policy-attribute-redirect-on-load.https.sub.html @@ -0,0 +1,36 @@ + + + + + + + diff --git a/testing/web-platform/tests/geolocation-API/enabled-by-permission-policy-attribute.https.sub.html b/testing/web-platform/tests/geolocation-API/enabled-by-permission-policy-attribute.https.sub.html new file mode 100644 index 0000000000..018409b829 --- /dev/null +++ b/testing/web-platform/tests/geolocation-API/enabled-by-permission-policy-attribute.https.sub.html @@ -0,0 +1,34 @@ + + + + + + + diff --git a/testing/web-platform/tests/geolocation-API/enabled-by-permissions-policy.https.sub.html b/testing/web-platform/tests/geolocation-API/enabled-by-permissions-policy.https.sub.html new file mode 100644 index 0000000000..007f79ab9c --- /dev/null +++ b/testing/web-platform/tests/geolocation-API/enabled-by-permissions-policy.https.sub.html @@ -0,0 +1,45 @@ + + + + + + + + + + diff --git a/testing/web-platform/tests/geolocation-API/enabled-by-permissions-policy.https.sub.html.headers b/testing/web-platform/tests/geolocation-API/enabled-by-permissions-policy.https.sub.html.headers new file mode 100644 index 0000000000..774f4819e9 --- /dev/null +++ b/testing/web-platform/tests/geolocation-API/enabled-by-permissions-policy.https.sub.html.headers @@ -0,0 +1 @@ +Permissions-Policy: geolocation=* diff --git a/testing/web-platform/tests/geolocation-API/enabled-on-self-origin-by-permissions-policy.https.sub.html b/testing/web-platform/tests/geolocation-API/enabled-on-self-origin-by-permissions-policy.https.sub.html new file mode 100644 index 0000000000..d879c1c543 --- /dev/null +++ b/testing/web-platform/tests/geolocation-API/enabled-on-self-origin-by-permissions-policy.https.sub.html @@ -0,0 +1,42 @@ + + + + + + + + + + diff --git a/testing/web-platform/tests/geolocation-API/enabled-on-self-origin-by-permissions-policy.https.sub.html.headers b/testing/web-platform/tests/geolocation-API/enabled-on-self-origin-by-permissions-policy.https.sub.html.headers new file mode 100644 index 0000000000..9fa0a4ac9a --- /dev/null +++ b/testing/web-platform/tests/geolocation-API/enabled-on-self-origin-by-permissions-policy.https.sub.html.headers @@ -0,0 +1 @@ +Permissions-Policy: geolocation=(self) diff --git a/testing/web-platform/tests/geolocation-API/getCurrentPosition_TypeError.https.html b/testing/web-platform/tests/geolocation-API/getCurrentPosition_TypeError.https.html new file mode 100644 index 0000000000..9da8ac1d29 --- /dev/null +++ b/testing/web-platform/tests/geolocation-API/getCurrentPosition_TypeError.https.html @@ -0,0 +1,61 @@ + + +Geolocation Test: getCurrentPosition TypeError tests + + + + + diff --git a/testing/web-platform/tests/geolocation-API/getCurrentPosition_permission_allow.https.html b/testing/web-platform/tests/geolocation-API/getCurrentPosition_permission_allow.https.html new file mode 100644 index 0000000000..c7fa970e08 --- /dev/null +++ b/testing/web-platform/tests/geolocation-API/getCurrentPosition_permission_allow.https.html @@ -0,0 +1,55 @@ + + +Geolocation Test: getCurrentPosition() location access + + + + + + diff --git a/testing/web-platform/tests/geolocation-API/getCurrentPosition_permission_deny.https.html b/testing/web-platform/tests/geolocation-API/getCurrentPosition_permission_deny.https.html new file mode 100644 index 0000000000..54bba9aeab --- /dev/null +++ b/testing/web-platform/tests/geolocation-API/getCurrentPosition_permission_deny.https.html @@ -0,0 +1,29 @@ + + +Geolocation Test: getCurrentPosition location access denied + + + + + + diff --git a/testing/web-platform/tests/geolocation-API/idlharness.https.window.js b/testing/web-platform/tests/geolocation-API/idlharness.https.window.js new file mode 100644 index 0000000000..eadd6b7a4f --- /dev/null +++ b/testing/web-platform/tests/geolocation-API/idlharness.https.window.js @@ -0,0 +1,14 @@ +// META: script=/resources/WebIDLParser.js +// META: script=/resources/idlharness.js +// META: script=/resources/testdriver.js +// META: script=/resources/testdriver-vendor.js + +// https://www.w3.org/TR/geolocation-API/ + +window.onload = async () => { + idl_test(["geolocation"], ["hr-time", "html"], (idl_array) => { + idl_array.add_objects({ + Geolocation: ["navigator.geolocation"], + }); + }); +}; diff --git a/testing/web-platform/tests/geolocation-API/non-fully-active.https.html b/testing/web-platform/tests/geolocation-API/non-fully-active.https.html new file mode 100644 index 0000000000..13853c0ef8 --- /dev/null +++ b/testing/web-platform/tests/geolocation-API/non-fully-active.https.html @@ -0,0 +1,106 @@ + + +Geolocation Test: non-fully active document + + + + + + + + diff --git a/testing/web-platform/tests/geolocation-API/non-secure-contexts.http.html b/testing/web-platform/tests/geolocation-API/non-secure-contexts.http.html new file mode 100644 index 0000000000..d491086cf8 --- /dev/null +++ b/testing/web-platform/tests/geolocation-API/non-secure-contexts.http.html @@ -0,0 +1,82 @@ + + +Geolocation Test: non-secure contexts + + + + diff --git a/testing/web-platform/tests/geolocation-API/permission.https.html b/testing/web-platform/tests/geolocation-API/permission.https.html new file mode 100644 index 0000000000..4062843349 --- /dev/null +++ b/testing/web-platform/tests/geolocation-API/permission.https.html @@ -0,0 +1,14 @@ + + +Test geolocation is a powerful feature via Permissions API + + + + diff --git a/testing/web-platform/tests/geolocation-API/resources/iframe.html b/testing/web-platform/tests/geolocation-API/resources/iframe.html new file mode 100644 index 0000000000..25cf3d92f3 --- /dev/null +++ b/testing/web-platform/tests/geolocation-API/resources/iframe.html @@ -0,0 +1,3 @@ + + +

Just a support file

diff --git a/testing/web-platform/tests/geolocation-API/support.js b/testing/web-platform/tests/geolocation-API/support.js new file mode 100644 index 0000000000..0f0e7f65b2 --- /dev/null +++ b/testing/web-platform/tests/geolocation-API/support.js @@ -0,0 +1,30 @@ +var geo; + +setup(function() { + geo = navigator.geolocation; +}); + +// The spec states that an implementation SHOULD acquire user permission before +// beginning the position acquisition steps. If an implementation follows this +// advice, set the following flag to aid debugging. +var isUsingPreemptivePermission = false; + + +var dummyFunction = function() {}; + +var positionToString = function(pos) { + var c = pos.coords; + return '[lat: ' + c.latitude + ', lon: ' + c.longitude + ', acc: ' + c.accuracy + ']'; +}; + +var errorToString = function(err) { + var codeString; + switch(err.code) { + case err.UNKNOWN_ERROR: codeString = 'UNKNOWN_ERROR'; break; + case err.PERMISSION_DENIED: codeString = 'PERMISSION_DENIED'; break; + case err.POSITION_UNAVAILABLE: codeString = 'POSITION_UNAVAILABLE'; break; + case err.TIMEOUT: codeString = 'TIMEOUT'; break; + default: codeString = 'undefined error code'; break; + } + return '[code: ' + codeString + ' (' + err.code + '), message: ' + (err.message ? err.message : '(empty)') + ']'; +}; diff --git a/testing/web-platform/tests/geolocation-API/watchPosition_TypeError.https.html b/testing/web-platform/tests/geolocation-API/watchPosition_TypeError.https.html new file mode 100644 index 0000000000..4ae7a89037 --- /dev/null +++ b/testing/web-platform/tests/geolocation-API/watchPosition_TypeError.https.html @@ -0,0 +1,65 @@ + + +Geolocation Test: watchPosition TypeError tests + + + + + diff --git a/testing/web-platform/tests/geolocation-API/watchPosition_permission_deny.https.html b/testing/web-platform/tests/geolocation-API/watchPosition_permission_deny.https.html new file mode 100644 index 0000000000..d47f2b5594 --- /dev/null +++ b/testing/web-platform/tests/geolocation-API/watchPosition_permission_deny.https.html @@ -0,0 +1,45 @@ + + +Geolocation Test: watchPosition location access denied + + + + + + -- cgit v1.2.3