turris-test-helpers

0.1.4 • Public • Published

Turris.js test environment helpers

Provides a simple way to create an environment for testing React.js components writter with ES6 without browser.

Includes things

  • jsdom with localStorage polyfill for all your DOM needs
  • React and TestUtils (exposed via mocha context)
  • Container for rendering your component that is create before each test and disposed afterwards (exposed via mocha context)
  • Should.js for your assertions (exposed as default module export)

Installation

Package can be installed using NPM:
npm install turris-test-helpers

Usage

It is recommended to import this file in the beginning of your test, e.g.:
import should from 'turris-test-helpers'

License

MIT

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 0.1.4
    1
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 0.1.4
    1
  • 0.1.3
    1
  • 0.1.2
    0

Package Sidebar

Install

npm i turris-test-helpers

Weekly Downloads

2

Version

0.1.4

License

MIT

Last publish

Collaborators

  • yamalight