- Revision
- 270048
- Author
- [email protected]
- Date
- 2020-11-19 13:06:46 -0800 (Thu, 19 Nov 2020)
Log Message
Regression(r267865) Geolocation API's error callback should be nullable
https://bugs.webkit.org/show_bug.cgi?id=219165
Reviewed by Geoffrey Garen.
LayoutTests/imported/w3c:
Rebaseline WPT test now that more checks are passing.
* web-platform-tests/geolocation-API/PositionOptions.https-expected.txt:
Source/WebCore:
Geolocation API's error callback should be nullable. The callback is nullable in both Firefox
and Chrome and there is at least one WPT test that fails unless the error callback is nullable.
The specification does not have this parameter as nullable. However, it is particularly risky
to be the only engine matching the specification here, especially considering that we used to
match other browser engines.
No new tests, updated / rebaselined existing tests.
* Modules/geolocation/Geolocation.idl:
LayoutTests:
Update existing test to reflect behavior change.
* fast/dom/Geolocation/argument-types-expected.txt:
* fast/dom/Geolocation/argument-types.html:
Modified Paths
Diff
Modified: trunk/LayoutTests/ChangeLog (270047 => 270048)
--- trunk/LayoutTests/ChangeLog 2020-11-19 21:05:02 UTC (rev 270047)
+++ trunk/LayoutTests/ChangeLog 2020-11-19 21:06:46 UTC (rev 270048)
@@ -1,3 +1,15 @@
+2020-11-19 Chris Dumez <[email protected]>
+
+ Regression(r267865) Geolocation API's error callback should be nullable
+ https://bugs.webkit.org/show_bug.cgi?id=219165
+
+ Reviewed by Geoffrey Garen.
+
+ Update existing test to reflect behavior change.
+
+ * fast/dom/Geolocation/argument-types-expected.txt:
+ * fast/dom/Geolocation/argument-types.html:
+
2020-11-19 Zalan Bujtas <[email protected]>
[Legacy Line Layout] Inline box's subpixel vertical top position should be enclosed
Modified: trunk/LayoutTests/fast/dom/Geolocation/argument-types-expected.txt (270047 => 270048)
--- trunk/LayoutTests/fast/dom/Geolocation/argument-types-expected.txt 2020-11-19 21:05:02 UTC (rev 270047)
+++ trunk/LayoutTests/fast/dom/Geolocation/argument-types-expected.txt 2020-11-19 21:06:46 UTC (rev 270048)
@@ -17,7 +17,7 @@
PASS navigator.geolocation.getCurrentPosition(-Infinity) threw exception TypeError: Argument 1 ('successCallback') to Geolocation.getCurrentPosition must be a function.
PASS navigator.geolocation.getCurrentPosition("string") threw exception TypeError: Argument 1 ('successCallback') to Geolocation.getCurrentPosition must be a function.
PASS navigator.geolocation.getCurrentPosition(emptyFunction, undefined) did not throw exception.
-PASS navigator.geolocation.getCurrentPosition(emptyFunction, null) threw exception TypeError: Argument 2 ('errorCallback') to Geolocation.getCurrentPosition must be a function.
+PASS navigator.geolocation.getCurrentPosition(emptyFunction, null) did not throw exception.
PASS navigator.geolocation.getCurrentPosition(emptyFunction, {}) threw exception TypeError: Argument 2 ('errorCallback') to Geolocation.getCurrentPosition must be a function.
PASS navigator.geolocation.getCurrentPosition(emptyFunction, objectThrowingException) threw exception TypeError: Argument 2 ('errorCallback') to Geolocation.getCurrentPosition must be a function.
PASS navigator.geolocation.getCurrentPosition(emptyFunction, emptyFunction) did not throw exception.
@@ -78,6 +78,7 @@
PASS navigator.geolocation.getCurrentPosition(emptyFunction, undefined, {timeout:Infinity}) did not throw exception.
PASS navigator.geolocation.getCurrentPosition(emptyFunction, undefined, {timeout:-Infinity}) did not throw exception.
PASS navigator.geolocation.getCurrentPosition(emptyFunction, undefined, {timeout:"string"}) did not throw exception.
+PASS navigator.geolocation.watchPosition(emptyFunction, null) did not throw exception.
PASS successfullyParsed is true
TEST COMPLETE
Modified: trunk/LayoutTests/fast/dom/Geolocation/argument-types.html (270047 => 270048)
--- trunk/LayoutTests/fast/dom/Geolocation/argument-types.html 2020-11-19 21:05:02 UTC (rev 270047)
+++ trunk/LayoutTests/fast/dom/Geolocation/argument-types.html 2020-11-19 21:06:46 UTC (rev 270048)
@@ -56,7 +56,7 @@
test('navigator.geolocation.getCurrentPosition("string")', true, "TypeError: Argument 1 ('successCallback') to Geolocation.getCurrentPosition must be a function");
test('navigator.geolocation.getCurrentPosition(emptyFunction, undefined)', false);
-test('navigator.geolocation.getCurrentPosition(emptyFunction, null)', true, "TypeError: Argument 2 ('errorCallback') to Geolocation.getCurrentPosition must be a function");
+test('navigator.geolocation.getCurrentPosition(emptyFunction, null)', false);
test('navigator.geolocation.getCurrentPosition(emptyFunction, {})', true, "TypeError: Argument 2 ('errorCallback') to Geolocation.getCurrentPosition must be a function");
test('navigator.geolocation.getCurrentPosition(emptyFunction, objectThrowingException)', true, "TypeError: Argument 2 ('errorCallback') to Geolocation.getCurrentPosition must be a function");
test('navigator.geolocation.getCurrentPosition(emptyFunction, emptyFunction)', false);
@@ -123,6 +123,8 @@
test('navigator.geolocation.getCurrentPosition(emptyFunction, undefined, {timeout:-Infinity})', false);
test('navigator.geolocation.getCurrentPosition(emptyFunction, undefined, {timeout:"string"})', false);
+test("navigator.geolocation.watchPosition(emptyFunction, null)", false);
+
window.jsTestIsAsync = false;
</script>
Modified: trunk/LayoutTests/imported/w3c/ChangeLog (270047 => 270048)
--- trunk/LayoutTests/imported/w3c/ChangeLog 2020-11-19 21:05:02 UTC (rev 270047)
+++ trunk/LayoutTests/imported/w3c/ChangeLog 2020-11-19 21:06:46 UTC (rev 270048)
@@ -1,3 +1,14 @@
+2020-11-19 Chris Dumez <[email protected]>
+
+ Regression(r267865) Geolocation API's error callback should be nullable
+ https://bugs.webkit.org/show_bug.cgi?id=219165
+
+ Reviewed by Geoffrey Garen.
+
+ Rebaseline WPT test now that more checks are passing.
+
+ * web-platform-tests/geolocation-API/PositionOptions.https-expected.txt:
+
2020-11-19 Darin Adler <[email protected]>
Remove extra copy of html5lib left over from an earlier Web Platform Tests import
Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/geolocation-API/PositionOptions.https-expected.txt (270047 => 270048)
--- trunk/LayoutTests/imported/w3c/web-platform-tests/geolocation-API/PositionOptions.https-expected.txt 2020-11-19 21:05:02 UTC (rev 270047)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/geolocation-API/PositionOptions.https-expected.txt 2020-11-19 21:06:46 UTC (rev 270048)
@@ -1,5 +1,5 @@
-FAIL Call getCurrentPosition with wrong type for enableHighAccuracy. No exception expected. assert_unreached: An exception was thrown unexpectedly: Argument 2 ('errorCallback') to Geolocation.getCurrentPosition must be a function Reached unreachable code
-FAIL Call watchPosition with wrong type for enableHighAccuracy. No exception expected. assert_unreached: An exception was thrown unexpectedly: Argument 2 ('errorCallback') to Geolocation.watchPosition must be a function Reached unreachable code
+PASS Call getCurrentPosition with wrong type for enableHighAccuracy. No exception expected.
+PASS Call watchPosition with wrong type for enableHighAccuracy. No exception expected.
FAIL PositionOptions tests promise_test: Unhandled rejection with value: object "Error: unimplemented"
Modified: trunk/Source/WebCore/ChangeLog (270047 => 270048)
--- trunk/Source/WebCore/ChangeLog 2020-11-19 21:05:02 UTC (rev 270047)
+++ trunk/Source/WebCore/ChangeLog 2020-11-19 21:06:46 UTC (rev 270048)
@@ -1,5 +1,23 @@
2020-11-19 Chris Dumez <[email protected]>
+ Regression(r267865) Geolocation API's error callback should be nullable
+ https://bugs.webkit.org/show_bug.cgi?id=219165
+
+ Reviewed by Geoffrey Garen.
+
+ Geolocation API's error callback should be nullable. The callback is nullable in both Firefox
+ and Chrome and there is at least one WPT test that fails unless the error callback is nullable.
+
+ The specification does not have this parameter as nullable. However, it is particularly risky
+ to be the only engine matching the specification here, especially considering that we used to
+ match other browser engines.
+
+ No new tests, updated / rebaselined existing tests.
+
+ * Modules/geolocation/Geolocation.idl:
+
+2020-11-19 Chris Dumez <[email protected]>
+
Unable to fetch an audio worklet module using a data URL
https://bugs.webkit.org/show_bug.cgi?id=219166
Modified: trunk/Source/WebCore/Modules/geolocation/Geolocation.idl (270047 => 270048)
--- trunk/Source/WebCore/Modules/geolocation/Geolocation.idl 2020-11-19 21:05:02 UTC (rev 270047)
+++ trunk/Source/WebCore/Modules/geolocation/Geolocation.idl 2020-11-19 21:06:46 UTC (rev 270048)
@@ -31,11 +31,11 @@
Exposed=Window
] interface Geolocation {
undefined getCurrentPosition(PositionCallback successCallback,
- optional PositionErrorCallback errorCallback,
+ optional PositionErrorCallback? errorCallback,
optional PositionOptions options);
long watchPosition(PositionCallback successCallback,
- optional PositionErrorCallback errorCallback,
+ optional PositionErrorCallback? errorCallback,
optional PositionOptions options);
undefined clearWatch(long watchId);