| Index: third_party/WebKit/LayoutTests/shapedetection/detectface-ImageBitmap.html
|
| diff --git a/third_party/WebKit/LayoutTests/shapedetection/detectface-ImageBitmap.html b/third_party/WebKit/LayoutTests/shapedetection/detectface-ImageBitmap.html
|
| deleted file mode 100644
|
| index b2c25cd333787c2cac2ec14b83387a126f70ba7d..0000000000000000000000000000000000000000
|
| --- a/third_party/WebKit/LayoutTests/shapedetection/detectface-ImageBitmap.html
|
| +++ /dev/null
|
| @@ -1,50 +0,0 @@
|
| -<!DOCTYPE html>
|
| -<script src="../resources/testharness.js"></script>
|
| -<script src="../resources/testharnessreport.js"></script>
|
| -<script src="../resources/mojo-helpers.js"></script>
|
| -<script src="resources/mock-shapedetection.js"></script>
|
| -<script>
|
| -
|
| -// This test verifies that FaceDetector.detect works on an ImageBitmap.
|
| -// Uses the mock mojo server implemented in mock-shapedetection.js.
|
| -async_test(function(t) {
|
| - var img = new Image();
|
| -
|
| - img.onload = function() {
|
| - var theImageBitmap = null;
|
| - var theMock = null;
|
| -
|
| - createImageBitmap(img)
|
| - .then(imageBitmap => {
|
| - theImageBitmap = imageBitmap;
|
| - return mockShapeDetectionReady;
|
| - })
|
| - .catch(error => {
|
| - assert_unreached('createImageBitmap() error: ' + error);
|
| - })
|
| - .then(mock => {
|
| - theMock = mock;
|
| - return new FaceDetector();
|
| - })
|
| - .catch(error => {
|
| - assert_unreached("Error creating MockShapeDetection: " + error);
|
| - })
|
| - .then(detector => {
|
| - return detector.detect(theImageBitmap);
|
| - })
|
| - .then(faceDetectionResult => {
|
| - const imageReceivedByMock = theMock.getFrameData();
|
| - assert_equals(imageReceivedByMock.byteLength, 2500,"Image length");
|
| - const GREEN_PIXEL = 0xFF00FF00;
|
| - assert_equals(imageReceivedByMock[0], GREEN_PIXEL, "Pixel color");
|
| - assert_equals(faceDetectionResult.length, 3, "Number of faces");
|
| - t.done();
|
| - })
|
| - .catch(error => {
|
| - assert_unreached("Error during detect(img): " + error);
|
| - });
|
| - }
|
| - img.src = '../media/content/greenbox.png';
|
| -}, 'exercises the ShapeDetection API detect(ImageBitmap)');
|
| -
|
| -</script>
|
|
|