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

Unified Diff: LayoutTests/fast/encoding/api/basics.html

Issue 313393005: Encoding API: Handle null input string (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 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
« no previous file with comments | « no previous file | Source/modules/encoding/TextEncoder.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/fast/encoding/api/basics.html
diff --git a/LayoutTests/fast/encoding/api/basics.html b/LayoutTests/fast/encoding/api/basics.html
index d95471265e0fc22add1a04c903ff2fa40e91ed1b..15b45a51edb6f226df45036735bf7c7c79d24bf5 100644
--- a/LayoutTests/fast/encoding/api/basics.html
+++ b/LayoutTests/fast/encoding/api/basics.html
@@ -23,6 +23,8 @@ test(function() {
assert_equals((new TextEncoder).encoding, 'utf-8', 'default encoding is utf-8');
assert_equals((new TextDecoder).encoding, 'utf-8', 'default encoding is utf-8');
+ assert_array_equals(new TextEncoder().encode(), [], 'input default should be empty string')
+
function testEncodeDecodeSample(encoding, string, bytes) {
var encoded = new TextEncoder(encoding).encode(string);
assert_array_equals([].slice.call(encoded), bytes);
« no previous file with comments | « no previous file | Source/modules/encoding/TextEncoder.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698