aweary/react-perimeter

Add test suite

Open

#5 ouverte le 17 mars 2017

Voir sur GitHub
 (4 commentaires) (2 réactions) (0 assignés)JavaScript (27 forks)github user discovery
good first bughelp wanted

Métriques du dépôt

Stars
 (1 042 stars)
Métriques de merge PR
 (Métriques PR en attente)

Description

It's probably hard to test the actual core feature of react-perimeter , but there are a few things we can definitely test:

  • correctly exports the React component
  • renders children
  • attaches ref correctly with render callbacks
  • registers event listeners on mount
  • removes event listeners on unmount
  • removes event listeners after onBreach is called if once is true
  • more stuff

I'd like to use jest and enzyme for this.

Guide contributeur