Skip to content

Commit 04713fc

Browse files
authored
Merge pull request #9264 from aickin/server-render-unit-tests-forms
Adding SSR test for form fields.
2 parents d9915db + a734aec commit 04713fc

File tree

4 files changed

+674
-15
lines changed

4 files changed

+674
-15
lines changed

scripts/fiber/tests-failing.txt

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,42 @@ src/renderers/dom/shared/__tests__/ReactDOMServerIntegration-test.js
102102
* renders >,<, and & as single child with client render on top of good server markup
103103
* renders >,<, and & as multiple children with server string render
104104
* renders >,<, and & as multiple children with client render on top of good server markup
105+
* renders an input with a value and an onChange with client render on top of good server markup
106+
* renders an input with a value and readOnly with client render on top of good server markup
107+
* renders an input with a value and no onChange/readOnly with client render on top of good server markup
108+
* renders an input with a defaultValue with client render on top of good server markup
109+
* renders an input value overriding defaultValue with client render on top of good server markup
110+
* renders an input value overriding defaultValue no matter the prop order with client render on top of good server markup
111+
* renders a checkbox that is checked with an onChange with client render on top of good server markup
112+
* renders a checkbox that is checked with readOnly with client render on top of good server markup
113+
* renders a checkbox that is checked and no onChange/readOnly with client render on top of good server markup
114+
* renders a checkbox with defaultChecked with client render on top of good server markup
115+
* renders a checkbox checked overriding defaultChecked with client render on top of good server markup
116+
* renders a checkbox checked overriding defaultChecked no matter the prop order with client render on top of good server markup
117+
* renders a textarea with a value and an onChange with client render on top of good server markup
118+
* renders a textarea with a value and readOnly with client render on top of good server markup
119+
* renders a textarea with a value and no onChange/readOnly with client render on top of good server markup
120+
* renders a textarea with a defaultValue with client render on top of good server markup
121+
* renders a textarea value overriding defaultValue with client render on top of good server markup
122+
* renders a textarea value overriding defaultValue no matter the prop order with client render on top of good server markup
123+
* renders a select with a value and an onChange with client render on top of good server markup
124+
* renders a select with a value and readOnly with client render on top of good server markup
125+
* renders a select with a multiple values and an onChange with client render on top of good server markup
126+
* renders a select with a multiple values and readOnly with client render on top of good server markup
127+
* renders a select with a value and no onChange/readOnly with client render on top of good server markup
128+
* renders a select with a defaultValue with client render on top of good server markup
129+
* renders a select value overriding defaultValue with client render on top of good server markup
130+
* renders a select value overriding defaultValue no matter the prop order with client render on top of good server markup
131+
* renders a controlled text input with client render on top of good server markup
132+
* renders a controlled textarea with client render on top of good server markup
133+
* renders a controlled checkbox with client render on top of good server markup
134+
* renders a controlled select with client render on top of good server markup
135+
* should not blow away user-entered text on successful reconnect to an uncontrolled input
136+
* should not blow away user-entered text on successful reconnect to a controlled input
137+
* should not blow away user-entered text on successful reconnect to an uncontrolled checkbox
138+
* should not blow away user-entered text on successful reconnect to a controlled checkbox
139+
* should not blow away user-selected value on successful reconnect to an uncontrolled select
140+
* should not blow away user-selected value on successful reconnect to an controlled select
105141
* renders class child with context with client render on top of good server markup
106142
* renders stateless child with context with client render on top of good server markup
107143
* renders class child without context with client render on top of good server markup

scripts/fiber/tests-passing-except-dev.txt

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,36 @@ src/renderers/dom/shared/__tests__/ReactDOMServerIntegration-test.js
9494
* throws when rendering an undefined component with client render on top of bad server markup
9595
* throws when rendering a number component with clean client render
9696
* throws when rendering a number component with client render on top of bad server markup
97+
* renders an input with a value and an onChange with client render on top of bad server markup
98+
* renders an input with a value and readOnly with client render on top of bad server markup
99+
* renders an input with a value and no onChange/readOnly with client render on top of bad server markup
100+
* renders an input with a defaultValue with client render on top of bad server markup
101+
* renders an input value overriding defaultValue with client render on top of bad server markup
102+
* renders an input value overriding defaultValue no matter the prop order with client render on top of bad server markup
103+
* renders a checkbox that is checked with an onChange with client render on top of bad server markup
104+
* renders a checkbox that is checked with readOnly with client render on top of bad server markup
105+
* renders a checkbox that is checked and no onChange/readOnly with client render on top of bad server markup
106+
* renders a checkbox with defaultChecked with client render on top of bad server markup
107+
* renders a checkbox checked overriding defaultChecked with client render on top of bad server markup
108+
* renders a checkbox checked overriding defaultChecked no matter the prop order with client render on top of bad server markup
109+
* renders a textarea with a value and an onChange with client render on top of bad server markup
110+
* renders a textarea with a value and readOnly with client render on top of bad server markup
111+
* renders a textarea with a value and no onChange/readOnly with client render on top of bad server markup
112+
* renders a textarea with a defaultValue with client render on top of bad server markup
113+
* renders a textarea value overriding defaultValue with client render on top of bad server markup
114+
* renders a textarea value overriding defaultValue no matter the prop order with client render on top of bad server markup
115+
* renders a select with a value and an onChange with client render on top of bad server markup
116+
* renders a select with a value and readOnly with client render on top of bad server markup
117+
* renders a select with a multiple values and an onChange with client render on top of bad server markup
118+
* renders a select with a multiple values and readOnly with client render on top of bad server markup
119+
* renders a select with a value and no onChange/readOnly with client render on top of bad server markup
120+
* renders a select with a defaultValue with client render on top of bad server markup
121+
* renders a select value overriding defaultValue with client render on top of bad server markup
122+
* renders a select value overriding defaultValue no matter the prop order with client render on top of bad server markup
123+
* renders a controlled text input with client render on top of bad server markup
124+
* renders a controlled textarea with client render on top of bad server markup
125+
* renders a controlled checkbox with client render on top of bad server markup
126+
* renders a controlled select with client render on top of bad server markup
97127
* renders class child with context with client render on top of bad server markup
98128
* renders stateless child with context with client render on top of bad server markup
99129
* renders class child without context with client render on top of bad server markup

scripts/fiber/tests-passing.txt

Lines changed: 56 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1154,6 +1154,62 @@ src/renderers/dom/shared/__tests__/ReactDOMServerIntegration-test.js
11541154
* throws when rendering string with server string render
11551155
* throws when rendering string with clean client render
11561156
* throws when rendering string with client render on top of bad server markup
1157+
* renders an input with a value and an onChange with server string render
1158+
* renders an input with a value and an onChange with clean client render
1159+
* renders an input with a value and readOnly with server string render
1160+
* renders an input with a value and readOnly with clean client render
1161+
* renders an input with a value and no onChange/readOnly with server string render
1162+
* renders an input with a value and no onChange/readOnly with clean client render
1163+
* renders an input with a defaultValue with server string render
1164+
* renders an input with a defaultValue with clean client render
1165+
* renders an input value overriding defaultValue with server string render
1166+
* renders an input value overriding defaultValue with clean client render
1167+
* renders an input value overriding defaultValue no matter the prop order with server string render
1168+
* renders an input value overriding defaultValue no matter the prop order with clean client render
1169+
* renders a checkbox that is checked with an onChange with server string render
1170+
* renders a checkbox that is checked with an onChange with clean client render
1171+
* renders a checkbox that is checked with readOnly with server string render
1172+
* renders a checkbox that is checked with readOnly with clean client render
1173+
* renders a checkbox that is checked and no onChange/readOnly with server string render
1174+
* renders a checkbox that is checked and no onChange/readOnly with clean client render
1175+
* renders a checkbox with defaultChecked with server string render
1176+
* renders a checkbox with defaultChecked with clean client render
1177+
* renders a checkbox checked overriding defaultChecked with server string render
1178+
* renders a checkbox checked overriding defaultChecked with clean client render
1179+
* renders a checkbox checked overriding defaultChecked no matter the prop order with server string render
1180+
* renders a checkbox checked overriding defaultChecked no matter the prop order with clean client render
1181+
* renders a textarea with a value and an onChange with server string render
1182+
* renders a textarea with a value and an onChange with clean client render
1183+
* renders a textarea with a value and readOnly with server string render
1184+
* renders a textarea with a value and readOnly with clean client render
1185+
* renders a textarea with a value and no onChange/readOnly with server string render
1186+
* renders a textarea with a value and no onChange/readOnly with clean client render
1187+
* renders a textarea with a defaultValue with server string render
1188+
* renders a textarea with a defaultValue with clean client render
1189+
* renders a textarea value overriding defaultValue with server string render
1190+
* renders a textarea value overriding defaultValue with clean client render
1191+
* renders a textarea value overriding defaultValue no matter the prop order with server string render
1192+
* renders a textarea value overriding defaultValue no matter the prop order with clean client render
1193+
* renders a select with a value and an onChange with server string render
1194+
* renders a select with a value and an onChange with clean client render
1195+
* renders a select with a value and readOnly with server string render
1196+
* renders a select with a value and readOnly with clean client render
1197+
* renders a select with a multiple values and an onChange with server string render
1198+
* renders a select with a multiple values and an onChange with clean client render
1199+
* renders a select with a multiple values and readOnly with server string render
1200+
* renders a select with a multiple values and readOnly with clean client render
1201+
* renders a select with a value and no onChange/readOnly with server string render
1202+
* renders a select with a value and no onChange/readOnly with clean client render
1203+
* renders a select with a defaultValue with server string render
1204+
* renders a select with a defaultValue with clean client render
1205+
* renders a select value overriding defaultValue with server string render
1206+
* renders a select value overriding defaultValue with clean client render
1207+
* renders a select value overriding defaultValue no matter the prop order with server string render
1208+
* renders a select value overriding defaultValue no matter the prop order with clean client render
1209+
* renders a controlled text input with clean client render
1210+
* renders a controlled textarea with clean client render
1211+
* renders a controlled checkbox with clean client render
1212+
* renders a controlled select with clean client render
11571213
* renders class child with context with server string render
11581214
* renders class child with context with clean client render
11591215
* renders stateless child with context with server string render
@@ -1193,7 +1249,6 @@ src/renderers/dom/shared/__tests__/ReactDOMServerIntegration-test.js
11931249
* should reconnect Pure Component to Bare Element
11941250
* should reconnect Bare Element to Bare Element
11951251
* should reconnect a div with a number and string version of number
1196-
* should reconnect if component trees differ but resulting markup is the same
11971252

11981253
src/renderers/dom/shared/__tests__/ReactDOMTextComponent-test.js
11991254
* updates a mounted text component in place

0 commit comments

Comments
 (0)