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

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

Issue 2086283003: Update web-platform-tests (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Merge branch 'master' into wpt_import Created 4 years, 6 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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/LayoutTests/imported/wpt/encoding/textdecoder-streaming.html
diff --git a/third_party/WebKit/LayoutTests/imported/wpt/encoding/textdecoder-streaming.html b/third_party/WebKit/LayoutTests/imported/wpt/encoding/textdecoder-streaming.html
index 211b3c00918c125bb688b1928c7532eb309db515..2b567aaa1e12914f696bc43801f4f9b636125f09 100644
--- a/third_party/WebKit/LayoutTests/imported/wpt/encoding/textdecoder-streaming.html
+++ b/third_party/WebKit/LayoutTests/imported/wpt/encoding/textdecoder-streaming.html
@@ -7,6 +7,9 @@
var string = '\x00123ABCabc\x80\xFF\u0100\u1000\uFFFD\uD800\uDC00\uDBFF\uDFFF';
var octets = {
+ 'utf-8': [0x00,0x31,0x32,0x33,0x41,0x42,0x43,0x61,0x62,0x63,0xc2,0x80,
+ 0xc3,0xbf,0xc4,0x80,0xe1,0x80,0x80,0xef,0xbf,0xbd,0xf0,0x90,
+ 0x80,0x80,0xf4,0x8f,0xbf,0xbf],
'utf-16le': [0x00,0x00,0x31,0x00,0x32,0x00,0x33,0x00,0x41,0x00,0x42,0x00,
0x43,0x00,0x61,0x00,0x62,0x00,0x63,0x00,0x80,0x00,0xFF,0x00,
0x00,0x01,0x00,0x10,0xFD,0xFF,0x00,0xD8,0x00,0xDC,0xFF,0xDB,
@@ -17,11 +20,10 @@ var octets = {
0xDF,0xFF]
};
-utf_encodings.forEach(function (encoding) {
+Object.keys(octets).forEach(function(encoding) {
for (var len = 1; len <= 5; ++len) {
test(function() {
- var encoded = octets[encoding] ||
- new TextEncoder(encoding).encode(string);
+ var encoded = octets[encoding];
var out = '';
var decoder = new TextDecoder(encoding);

Powered by Google App Engine
This is Rietveld 408576698