xhr: added more tests to xhr.js