Frontend testing with Mocha, Chai, and Sinon