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

Unified Diff: LayoutTests/fast/dom/element-attribute-js-null.html

Issue 98383004: Remove TreatNullAs=NullString for HTMLInputElement (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: rebase Created 7 years 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: LayoutTests/fast/dom/element-attribute-js-null.html
diff --git a/LayoutTests/fast/dom/element-attribute-js-null.html b/LayoutTests/fast/dom/element-attribute-js-null.html
index a1aa9b1ae3f8ca5e807afe53aa216a8acd493bfc..f1c5fdf19d6de779791645576d900f736a53fc5e 100644
--- a/LayoutTests/fast/dom/element-attribute-js-null.html
+++ b/LayoutTests/fast/dom/element-attribute-js-null.html
@@ -351,16 +351,38 @@
type: 'HTMLInputElement',
elementToUse: document.createElement('input'),
attributes: [
- {name: 'accept', expectedNull: ''},
+ {name: 'accept', expectedNull: 'null'},
{name: 'accessKey', expectedNull: ''},
- {name: 'align', expectedNull: ''},
- {name: 'alt', expectedNull: ''},
- {name: 'defaultValue', expectedNull: ''},
- {name: 'name', expectedNull: ''},
- {name: 'src', expectedNull: ''},
+ {name: 'align', expectedNull: 'null'},
+ {name: 'alt', expectedNull: 'null'},
+ {name: 'autocomplete', expectedNull: 'null'},
+ {name: 'defaultValue', expectedNull: 'null'},
+ {name: 'dirName', expectedNull: 'null'},
+ {name: 'formAction', expectedNull: 'null', isUrl: true},
+ {name: 'formEnctype', expectedNull: 'application/x-www-form-urlencoded'},
+ {name: 'formMethod', expectedNull: 'get'},
+ {name: 'formTarget', expectedNull: 'null'},
+ {name: 'max', expectedNull: 'null'},
+ {name: 'min', expectedNull: 'null'},
+ {name: 'name', expectedNull: 'null'},
+ {name: 'pattern', expectedNull: 'null'},
+ {name: 'placeholder', expectedNull: 'null'},
+ {name: 'src', expectedNull: 'null', isUrl: true},
+ {name: 'step', expectedNull: 'null'},
{name: 'type', expectedNull: 'text'},
- {name: 'useMap', expectedNull: ''},
- {name: 'value', expectedNull: ''},
+ {name: 'useMap', expectedNull: 'null'}
+ ]
+ },
+ // [TreatNullAs=NullString] is not identical to [TreatNullAs=EmptyString] because
+ // null and empty string can be distinguished. A side-effect is that setting
+ // HTMLInputElement.value to null does clear the old value. This would be fixed by
+ // using [TreatNullAs=EmptyString], but until then test value separately to avoid
+ // interference from the defaultValue test.
+ {
+ type: 'HTMLInputElement',
+ elementToUse: document.createElement('input'),
+ attributes: [
+ {name: 'value', expectedNull: ''}
]
},
{

Powered by Google App Engine
This is Rietveld 408576698