From 977bf7caaf326ed155c1f5d200c544a020178840 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matija=20Marohni=C4=87?= Date: Fri, 24 Jul 2015 18:23:24 +0200 Subject: [PATCH] Fix React warnings in tests --- specs/Element-spec.jsx | 17 ++++++++++------- specs/Formsy-spec.jsx | 14 +++++++------- specs/Validation-spec.jsx | 8 ++++---- 3 files changed, 21 insertions(+), 18 deletions(-) diff --git a/specs/Element-spec.jsx b/specs/Element-spec.jsx index d517f37..20f3ea5 100644 --- a/specs/Element-spec.jsx +++ b/specs/Element-spec.jsx @@ -198,8 +198,11 @@ describe('Element', function() { it('should allow an undefined value to be updated to a value', function (done) { var TestInput = React.createClass({ mixins: [Formsy.Mixin], + changeValue: function (event) { + this.setValue(event.target.value); + }, render: function () { - return + return } }); var TestForm = React.createClass({ @@ -237,7 +240,7 @@ it('should allow an undefined value to be updated to a value', function (done) { var TestInput = React.createClass({ mixins: [Formsy.Mixin], render: function () { - return + return } }); var TestForm = React.createClass({ @@ -264,7 +267,7 @@ it('should allow an undefined value to be updated to a value', function (done) { var TestInput = React.createClass({ mixins: [Formsy.Mixin], render: function () { - return + return } }); var TestForm = React.createClass({ @@ -368,7 +371,7 @@ it('should allow an undefined value to be updated to a value', function (done) { var TestInput = React.createClass({ mixins: [Formsy.Mixin], render: function () { - return + return } }); var TestForm = React.createClass({ @@ -394,7 +397,7 @@ it('should allow an undefined value to be updated to a value', function (done) { var TestInput = React.createClass({ mixins: [Formsy.Mixin], render: function () { - return + return } }); var TestForm = React.createClass({ @@ -428,7 +431,7 @@ it('should allow an undefined value to be updated to a value', function (done) { var TestInput = React.createClass({ mixins: [Formsy.Mixin], render: function () { - return + return } }); var TestForm = React.createClass({ @@ -459,7 +462,7 @@ it('should allow an undefined value to be updated to a value', function (done) { var TestInput = React.createClass({ mixins: [Formsy.Mixin], render: function () { - return + return } }); var TestForm = React.createClass({ diff --git a/specs/Formsy-spec.jsx b/specs/Formsy-spec.jsx index 5f74041..34d3250 100755 --- a/specs/Formsy-spec.jsx +++ b/specs/Formsy-spec.jsx @@ -84,7 +84,7 @@ describe('Formsy', function () { // Wait before adding the input setTimeout(function () { - inputs.push(); + inputs.push(); forceUpdate(function () { // Wait for next event loop, as that does the form @@ -135,7 +135,7 @@ describe('Formsy', function () { // Wait before adding the input setTimeout(function () { - inputs.push(); + inputs.push(); forceUpdate(function () { @@ -377,7 +377,7 @@ describe('Formsy', function () { ); // Wait before adding the input - inputs.push(); + inputs.push(); forceUpdate(function () { @@ -400,7 +400,7 @@ describe('Formsy', function () { var TestInput = React.createClass({ mixins: [Formsy.Mixin], render: function () { - return + return } }); var TestForm = React.createClass({ @@ -438,7 +438,7 @@ describe('Formsy', function () { var TestInput = React.createClass({ mixins: [Formsy.Mixin], render: function () { - return ; + return ; } }); var TestForm = React.createClass({ @@ -493,7 +493,7 @@ describe('Formsy', function () { var TestInput = React.createClass({ mixins: [Formsy.Mixin], render: function () { - return ; + return ; } }); var TestForm = React.createClass({ @@ -523,7 +523,7 @@ describe('Formsy', function () { var TestInput = React.createClass({ mixins: [Formsy.Mixin], render: function () { - return ; + return ; } }); var TestForm = React.createClass({ diff --git a/specs/Validation-spec.jsx b/specs/Validation-spec.jsx index cf92542..fd6fabe 100644 --- a/specs/Validation-spec.jsx +++ b/specs/Validation-spec.jsx @@ -160,7 +160,7 @@ describe('Validation', function() { var TestInput = React.createClass({ mixins: [Formsy.Mixin], render: function () { - return + return } }); var TestForm = React.createClass({ @@ -191,7 +191,7 @@ describe('Validation', function() { var TestInput = React.createClass({ mixins: [Formsy.Mixin], render: function () { - return + return } }); var TestForm = React.createClass({ @@ -223,7 +223,7 @@ describe('Validation', function() { var TestInput = React.createClass({ mixins: [Formsy.Mixin], render: function () { - return + return } }); var TestForm = React.createClass({ @@ -253,7 +253,7 @@ describe('Validation', function() { var TestInput = React.createClass({ mixins: [Formsy.Mixin], render: function () { - return + return } }); var TestForm = React.createClass({