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

Side by Side Diff: third_party/WebKit/LayoutTests/imported/wpt/encoding/textdecoder-streaming.html

Issue 1984023002: Move web-platform-tests to wpt (part 1 of 2) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 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
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 <title>Encoding API: Streaming decode</title> 2 <title>Encoding API: Streaming decode</title>
3 <script src="../../../resources/testharness.js"></script> 3 <script src="../../../resources/testharness.js"></script>
4 <script src="../../../resources/testharnessreport.js"></script> 4 <script src="../../../resources/testharnessreport.js"></script>
5 <script src="resources/encodings.js"></script> 5 <script src="resources/encodings.js"></script>
6 <script> 6 <script>
7 7
8 var string = '\x00123ABCabc\x80\xFF\u0100\u1000\uFFFD\uD800\uDC00\uDBFF\uDFFF'; 8 var string = '\x00123ABCabc\x80\xFF\u0100\u1000\uFFFD\uD800\uDC00\uDBFF\uDFFF';
9 var octets = { 9 var octets = {
10 'utf-16le': [0x00,0x00,0x31,0x00,0x32,0x00,0x33,0x00,0x41,0x00,0x42,0x00, 10 'utf-16le': [0x00,0x00,0x31,0x00,0x32,0x00,0x33,0x00,0x41,0x00,0x42,0x00,
(...skipping 20 matching lines...) Expand all
31 sub.push(encoded[j]); 31 sub.push(encoded[j]);
32 out += decoder.decode(new Uint8Array(sub), {stream: true}); 32 out += decoder.decode(new Uint8Array(sub), {stream: true});
33 } 33 }
34 out += decoder.decode(); 34 out += decoder.decode();
35 assert_equals(out, string); 35 assert_equals(out, string);
36 }, 'Streaming decode: ' + encoding + ', ' + len + ' byte window'); 36 }, 'Streaming decode: ' + encoding + ', ' + len + ' byte window');
37 } 37 }
38 }); 38 });
39 39
40 </script> 40 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698