fix warnings in ReactComponentLifeCycle test
Don't use inputs to avoid warnings in tests
Jan Kassens committed
Apr 23, 2014 at 13:27 UTC
9e9d8dbe76db93db6176d041d186c10480f4d63c
1 file changed
+6
-11
src/core/__tests__/ReactComponentLifeCycle-test.js
+6
-11
@@ -356,15 +356,15 @@ describe('ReactComponentLifeCycle', function() {
356
var PropsUpdaterInOnDOMReady = React.createClass({
357
componentDidMount: function() {
358
this.refs.theSimpleComponent.setProps({
359
- value: this.props.valueToUseInOnDOMReady
359
+ valueToUseInitially: this.props.valueToUseInOnDOMReady
360
});
361
},
362
render: function() {
363
return (
364
- <input
365
- value={this.props.valueToUseInitially}
366
- ref="theSimpleComponent">
367
- </input>
364
+ <div
365
+ className={this.props.valueToUseInitially}
366
+ ref="theSimpleComponent"
367
+ />
368
);
369
}
370
});
@@ -429,12 +429,7 @@ describe('ReactComponentLifeCycle', function() {
429
function() {
430
var PropsToUpdate = React.createClass({
431
render: function() {
432
- return (
433
- <input
434
- value={this.props.value}
435
- ref="theSimpleComponent">
436
- </input>
437
- );
432
+ return <div className={this.props.value} ref="theSimpleComponent" />;
433
}
434
});
435
var instance = <PropsToUpdate value="hello" />;