How do I mock out executing a child process in Jest
const execSync = require('child_process').execSync; //... expect(execSync) .toHaveBeenCalledWith('npm install');
But not actually have it run the npm install during the test.
Aucun commentaire:
Enregistrer un commentaire