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

Side by Side Diff: third_party/WebKit/LayoutTests/http/tests/shapedetection/shapedetection-cross-origin.html

Issue 2658093004: Update a few references to imported/wpt (now external/wpt) (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/fast/forms/setrangetext.html ('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 <script src=../../../../resources/testharness.js></script> 2 <script src=../../../../resources/testharness.js></script>
3 <script src=../../../../resources/testharnessreport.js></script> 3 <script src=../../../../resources/testharnessreport.js></script>
4 <script> 4 <script>
5 5
6 // http:// resources are considered cross-origin from the current file://. 6 // http:// resources are considered cross-origin from the current file://.
7 const IMAGE_URL = "http://localhost:8080/security/resources/abe.png"; 7 const IMAGE_URL = "http://localhost:8080/security/resources/abe.png";
8 const VIDEO_URL = "http://localhost:8080/imported/wpt/media/white.webm"; 8 const VIDEO_URL = "http://localhost:8080/external/wpt/media/white.webm";
9 9
10 // Returns a Promise that is resolve()d if detect() is rejected. Needs an input 10 // Returns a Promise that is resolve()d if detect() is rejected. Needs an input
11 // |element| (e.g. an HTMLImageElement or HTMLVideoElement) and a |url| to load. 11 // |element| (e.g. an HTMLImageElement or HTMLVideoElement) and a |url| to load.
12 function detectFaceOnElementAndExpectError(element, url) { 12 function detectFaceOnElementAndExpectError(element, url) {
13 return new Promise(function(resolve, reject) { 13 return new Promise(function(resolve, reject) {
14 var tryFaceDetection = function() { 14 var tryFaceDetection = function() {
15 var faceDetector = new FaceDetector(); 15 var faceDetector = new FaceDetector();
16 faceDetector.detect(element) 16 faceDetector.detect(element)
17 .then(faceDetectionResult => { 17 .then(faceDetectionResult => {
18 reject("Promise should have been rejected."); 18 reject("Promise should have been rejected.");
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 promise_test(function(t) { 71 promise_test(function(t) {
72 var video = document.createElement('video'); 72 var video = document.createElement('video');
73 return detectFaceOnElementAndExpectError(video, VIDEO_URL) 73 return detectFaceOnElementAndExpectError(video, VIDEO_URL)
74 .then(error => { 74 .then(error => {
75 assert_equals(error.name, "SecurityError"); 75 assert_equals(error.name, "SecurityError");
76 }); 76 });
77 }, 77 },
78 "FaceDetector should reject cross-origin HTMLImageElements with a SecurityError. "); 78 "FaceDetector should reject cross-origin HTMLImageElements with a SecurityError. ");
79 79
80 </script> 80 </script>
OLDNEW
« no previous file with comments | « third_party/WebKit/LayoutTests/fast/forms/setrangetext.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698