mercredi 25 janvier 2017

How to simulate time passing in react in enzyme/mocha component tests

I have component which changes its state after some time. I'm using

setTimeout(function(){setState(), someTime)

to alter state.

Is it possible to mock passing someTime?

Aucun commentaire:

Enregistrer un commentaire