Skip to content
A framework to test a React Native app during runtime
Branch: master
Clone or download
Latest commit ea2d378 Mar 26, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
example Delete yarn.lock Mar 26, 2019
src Refactors code Feb 9, 2018
.eslintrc Adds stacktrace Nov 19, 2017
.gitignore 🎉 initial commit Nov 18, 2017
.npmignore 🎉 initial commit Nov 18, 2017
LICENSE 🎉 initial commit Nov 18, 2017
README.md Update README.md Nov 22, 2017
package-lock.json 0.0.4 Feb 9, 2018
package.json 0.0.4 Feb 9, 2018
screenshot.png Add screenshots and export properly Nov 20, 2017
works-with-yeti.png 🎉 initial commit Nov 18, 2017
yarn.lock Adds stacktrace Nov 19, 2017

README.md

react-native-diagnose

npm version

A react runtime diagnose component

Rationale

  • Testing native applications is complicated
  • There are features that can only be tested on a device, unless mocked
  • You may want to test your app on a production build, before submit it to the stores
import { Diagnose, Test } from 'react-diagnose'

/**
 * Diagnose will run all test components inside
 * Test components are going to be marked visually as completed or not
 * to d
 */
return (
  <Diagnose suiteTitle="Diagnose">
    <Test should="Passing test" />
    <Test should="Unfinished test" run={() => {
      return new Promise(() => setTimeout(() => {}, 1000000))
    }} />
    <Test should="Failed test" run={() => {throw new Error('Failing test')}} />
    <Test should="Dummy test" />
  </Diagnose>
)

demo screenshot

Help wanted

  • Elapsed time
  • Before all
  • Before each
  • After each
  • After all

More documentation is incoming, in the meanwhile please read the source code. It is a single file! PRs and issues are more than welcome.

works with yeti

 This package powers Yeti Smart Home and is used in production.

Follow us in Github or https://twitter.com/netbeast_co.

You can’t perform that action at this time.