rolled back the sinon code to leave the example in a more simplistic / working state