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

Unified Diff: LayoutTests/fast/forms/input-value-sanitization.html

Issue 189843008: Value sanitization for input[type=text] should not truncate a value at control character (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@bug196640
Patch Set: Removed control characters truncation logic to match firefox and IE behavior Created 6 years, 9 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 | LayoutTests/fast/forms/input-value-sanitization-expected.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/fast/forms/input-value-sanitization.html
diff --git a/LayoutTests/fast/forms/input-value-sanitization.html b/LayoutTests/fast/forms/input-value-sanitization.html
index 92e3f533198be135bd014085a6e99ef7be365974..92d59c27ecb32ffc761901e1b1a5c29239aab632 100644
--- a/LayoutTests/fast/forms/input-value-sanitization.html
+++ b/LayoutTests/fast/forms/input-value-sanitization.html
@@ -55,6 +55,30 @@ shouldBe('document.getSelection().toString()', '" foo bar "');
input.value = String.fromCharCode(0xD800);
shouldBe('input.value', 'String.fromCharCode(0xD800)');
+input.value="foo\0bar";
tkent 2014/03/11 04:03:06 Please add spaces around '='.
Habib Virji 2014/03/11 11:17:49 Done.
+shouldBe('input.value', '"foo\\0bar"');
tkent 2014/03/11 04:03:06 Please use shouldBeEqualToString.
Habib Virji 2014/03/11 11:17:49 Done.
+
+input.value="foo\abar";
+shouldBe('input.value', '"foo\\abar"');
+
+input.value="foo\bbar";
+shouldBe('input.value', '"foo\\bbar"');
+
+input.value="foo\tbar";
+shouldBe('input.value', '"foo\\tbar"');
+
+input.value="foo\vbar";
+shouldBe('input.value', '"foo\\vbar"');
+
+input.value="foo\fbar";
+shouldBe('input.value', '"foo\\fbar"');
+
+input.value="foo\ebar";
+shouldBe('input.value', '"foo\\ebar"');
+
+input.value="foo\^?bar";
+shouldBe('input.value', '"foo\\^?bar"');
+
// FIXME: Add more sanitization tests.
// https://bugs.webkit.org/show_bug.cgi?id=37024
« no previous file with comments | « no previous file | LayoutTests/fast/forms/input-value-sanitization-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698