Socket
Socket
Sign inDemoInstall

react-better-test

Package Overview
Dependencies
Maintainers
12
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-better-test

Better React test utils


Version published
Weekly downloads
0
Maintainers
12
Weekly downloads
 
Created
Source

react-better-test

Better React test utils npm version CircleCI Coverage Status


Installation

npm i -D react-better-test styled-components react-test-renderer redux react-redux react-router enzyme.

Usage

import renderer from 'react-better-test'
import 'jest-styled-components'
import Adapter from 'enzyme-adapter-react-16'
import enzyme from 'enzyme'
enzyme.configure({ adapter: new Adapter() })

// ...
expect(renderer.create(<Foo />)).toMatchSnapshot()
expect(renderer.mount(<SomeStyledComponent />)).toHaveStyleRule('color', 'blue')

See the tests for full usage examples.

TODO:

  • Finish Flow
  • Fix skipped tests

License

MIT

Keywords

FAQs

Package last updated on 28 Nov 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc