Fantastic Unit Tests in JavaScript with Mocks
michelenasti.com
michelenasti.com
this doesn't work for the awful practice encouraged by eslint (at least when i last tried it) that consists of ignoring that there exists a keyword specifically for declaring functions, and abusing constants with arrow functions instead
sure, it prevents you from reassigning the function variable and using `this` but aren't those things what you use a linter for?