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

Side by Side Diff: LayoutTests/fast/mediarecorder/BlobEvent-basic.html

Issue 1354863002: MediaRecorder: Adding BlobEvent and connecting it in MediaRecorderHandler (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: BlobEvent in global-interface-listing-expected.txt, and rebase Created 5 years, 3 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 | « no previous file | LayoutTests/fast/mediarecorder/MediaRecorder-basic-video.html » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 <!DOCTYPE html>
2 <script src=../../resources/testharness.js></script>
3 <script src=../../resources/testharnessreport.js></script>
4 <script>
5
6 test(function() {
7 var array = new Uint8Array([0x70, 0x71, 0x72, 0x73]);
8 var blob = new Blob([array]);
9 var blobEvent = new BlobEvent('BlobEvent', {data : blob});
10
11 var reader = new FileReader();
12 reader.addEventListener("loadend", function() {
13 // |reader.result| contains the contents of blob as an ArrayBuffer.
14 var outputArray = new Uint8Array(reader.result);
15 assert_equals(array.length, outputArray.length);
16 for (var index in outputArray) {
17 assert_equals(array[index], outputArray[index]);
18 }
19 });
20 reader.readAsArrayBuffer(blob);
21
22 }, 'check BlobEvent creation and content management');
23
24
25 </script>
OLDNEW
« no previous file with comments | « no previous file | LayoutTests/fast/mediarecorder/MediaRecorder-basic-video.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698