Skip to content

Instantly share code, notes, and snippets.

@mklymyshyn
Created February 25, 2015 18:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mklymyshyn/bde18104e6c792f47bd2 to your computer and use it in GitHub Desktop.
Save mklymyshyn/bde18104e6c792f47bd2 to your computer and use it in GitHub Desktop.
/** @jsx React.DOM */
// __tests__/form-test.js
jest.dontMock('../form.jsx');
describe('contact form', function() {
it('have name and text fields', function() {
var React = require('react/addons');
var utils = React.addons.TestUtils;
var Form = require('../form.jsx');
var form = utils.renderIntoDocument(<Form />);
expect(utils.findRenderedDOMComponentWithTag(form, "input")).not.toEqual(null);
});
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment