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

Unified Diff: LayoutTests/fast/forms/select/select-add-expected.txt

Issue 879273002: Adding tests for HTMLSelect add() api (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 11 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: LayoutTests/fast/forms/select/select-add-expected.txt
diff --git a/LayoutTests/fast/forms/select/select-add-expected.txt b/LayoutTests/fast/forms/select/select-add-expected.txt
index 4074af6c39aab0dd66d6247b43aeb01e7b87b42c..0434adc891f9828e46883110bf3ec2c03e476cd2 100644
--- a/LayoutTests/fast/forms/select/select-add-expected.txt
+++ b/LayoutTests/fast/forms/select/select-add-expected.txt
@@ -17,6 +17,14 @@ PASS addOption(NaN) is "X,0,1,2"
PASS addOption(Infinity) is "X,0,1,2"
PASS addOption(-Infinity) is "X,0,1,2"
PASS addOption("foo") is "X,0,1,2"
+PASS addOption("0") is "X,0,1,2"
+PASS addOption("1") is "0,X,1,2"
+PASS addOption(false) is "X,0,1,2"
+PASS addOption(true) is "0,X,1,2"
+PASS addOption(2147483647) is "0,1,2,X"
+PASS addOption(-2147483647) is "0,1,2,X"
+PASS addOption(2147483648) is "0,1,2,X"
+PASS addOption(-2147483648) is "0,1,2,X"
PASS select.add() threw exception TypeError: Failed to execute 'add' on 'HTMLSelectElement': 1 argument required, but only 0 present..
PASS select.add("foo") threw exception TypeError: Failed to execute 'add' on 'HTMLSelectElement': The provided value is not of type '(HTMLOptionElement or HTMLOptGroupElement)'.
PASS select.add("foo", 0) threw exception TypeError: Failed to execute 'add' on 'HTMLSelectElement': The provided value is not of type '(HTMLOptionElement or HTMLOptGroupElement)'.
@@ -24,6 +32,8 @@ PASS select.add(undefined) threw exception TypeError: Failed to execute 'add' on
PASS select.add(undefined, 0) threw exception TypeError: Failed to execute 'add' on 'HTMLSelectElement': The provided value is not of type '(HTMLOptionElement or HTMLOptGroupElement)'.
PASS select.add(null) threw exception TypeError: Failed to execute 'add' on 'HTMLSelectElement': The provided value is not of type '(HTMLOptionElement or HTMLOptGroupElement)'.
PASS select.add(null, 0) threw exception TypeError: Failed to execute 'add' on 'HTMLSelectElement': The provided value is not of type '(HTMLOptionElement or HTMLOptGroupElement)'.
+PASS select.add(new Option("X", "X", false, false), 0, 1) is undefined.
+PASS select.add(new Option("X", "X", false, false), select.options[0], 2) is undefined.
PASS getSelectOptions() is "0,X,Y,1,2"
Test select multiple
PASS addOption(0) is "X,0,1,2"
@@ -39,6 +49,14 @@ PASS addOption(NaN) is "X,0,1,2"
PASS addOption(Infinity) is "X,0,1,2"
PASS addOption(-Infinity) is "X,0,1,2"
PASS addOption("foo") is "X,0,1,2"
+PASS addOption("0") is "X,0,1,2"
+PASS addOption("1") is "0,X,1,2"
+PASS addOption(false) is "X,0,1,2"
+PASS addOption(true) is "0,X,1,2"
+PASS addOption(2147483647) is "0,1,2,X"
+PASS addOption(-2147483647) is "0,1,2,X"
+PASS addOption(2147483648) is "0,1,2,X"
+PASS addOption(-2147483648) is "0,1,2,X"
PASS select.add() threw exception TypeError: Failed to execute 'add' on 'HTMLSelectElement': 1 argument required, but only 0 present..
PASS select.add("foo") threw exception TypeError: Failed to execute 'add' on 'HTMLSelectElement': The provided value is not of type '(HTMLOptionElement or HTMLOptGroupElement)'.
PASS select.add("foo", 0) threw exception TypeError: Failed to execute 'add' on 'HTMLSelectElement': The provided value is not of type '(HTMLOptionElement or HTMLOptGroupElement)'.
@@ -46,6 +64,8 @@ PASS select.add(undefined) threw exception TypeError: Failed to execute 'add' on
PASS select.add(undefined, 0) threw exception TypeError: Failed to execute 'add' on 'HTMLSelectElement': The provided value is not of type '(HTMLOptionElement or HTMLOptGroupElement)'.
PASS select.add(null) threw exception TypeError: Failed to execute 'add' on 'HTMLSelectElement': The provided value is not of type '(HTMLOptionElement or HTMLOptGroupElement)'.
PASS select.add(null, 0) threw exception TypeError: Failed to execute 'add' on 'HTMLSelectElement': The provided value is not of type '(HTMLOptionElement or HTMLOptGroupElement)'.
+PASS select.add(new Option("X", "X", false, false), 0, 1) is undefined.
+PASS select.add(new Option("X", "X", false, false), select.options[0], 2) is undefined.
PASS getSelectOptions() is "0,X,Y,1,2"
PASS successfullyParsed is true

Powered by Google App Engine
This is Rietveld 408576698