Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(4)

Side by Side Diff: third_party/WebKit/LayoutTests/http/tests/security/powerfulFeatureRestrictions/resources/geolocation.html

Issue 2671933003: Move Geolocation out from fast/dom. (Closed)
Patch Set: . Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « third_party/WebKit/LayoutTests/geolocation-api/window-close-crash-expected.txt ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 <title>Geolocation On A Secure Origin</title> 2 <title>Geolocation On A Secure Origin</title>
3 <script src="/js-test-resources/mojo-helpers.js"></script> 3 <script src="/js-test-resources/mojo-helpers.js"></script>
4 <script src="/fast/dom/Geolocation/js-test-resources/geolocation-mock.js"></scri pt> 4 <script src="/geolocation-api/js-test-resources/geolocation-mock.js"></script>
5 <script> 5 <script>
6 var mockLatitude = 51.478; 6 var mockLatitude = 51.478;
7 var mockLongitude = -0.166; 7 var mockLongitude = -0.166;
8 var mockAccuracy = 100.0; 8 var mockAccuracy = 100.0;
9 9
10 if (!window.mojo) 10 if (!window.mojo)
11 console.error('This test can not run without mojo'); 11 console.error('This test can not run without mojo');
12 12
13 geolocationServiceMock.then(mock => { 13 geolocationServiceMock.then(mock => {
14 mock.setGeolocationPermission(true); 14 mock.setGeolocationPermission(true);
15 mock.setGeolocationPosition(mockLatitude, mockLongitude, mockAccuracy); 15 mock.setGeolocationPosition(mockLatitude, mockLongitude, mockAccuracy);
16 16
17 navigator.geolocation.getCurrentPosition( 17 navigator.geolocation.getCurrentPosition(
18 function () { 18 function () {
19 window.parent.postMessage({ success: true }, "*"); 19 window.parent.postMessage({ success: true }, "*");
20 }, 20 },
21 function (error) { 21 function (error) {
22 window.parent.postMessage({ message: error.message }, "*"); 22 window.parent.postMessage({ message: error.message }, "*");
23 }, { maximumAge: 10000 }); 23 }, { maximumAge: 10000 });
24 }); 24 });
25 </script> 25 </script>
OLDNEW
« no previous file with comments | « third_party/WebKit/LayoutTests/geolocation-api/window-close-crash-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698