TESTS: Integration tests for badge pages

This commit is contained in:
Robin Ward
2014-07-31 18:44:32 -04:00
parent 77332e8b57
commit d7ad3bb2b6
5 changed files with 31 additions and 6 deletions

View File

@ -1,5 +1,3 @@
/* global console */
function parsePostData(query) {
var result = {};
query.split("&").forEach(function(part) {
@ -60,7 +58,9 @@ export default function() {
};
server.unhandledRequest = function(verb, path) {
console.error('Unhandled request in test environment: ' + path + ' (' + verb + ')');
var error = 'Unhandled request in test environment: ' + path + ' (' + verb + ')';
window.console.error(error);
throw error;
};
return server;