Add initial tests, using mocha, sinon and xmlhttprequest to provide mocks