aboutsummaryrefslogtreecommitdiffstats
path: root/test/angular-mocks.js
diff options
context:
space:
mode:
authorShyam Seshadri2010-10-07 09:31:19 -0700
committerMisko Hevery2010-10-07 09:34:22 -0700
commitc30807d1413ea9942bcb065a02997082bf4291aa (patch)
treeb996da45c7ef39029f7342639eecbb246de69af7 /test/angular-mocks.js
parenta930e782a56eca047130e5a32f1ce97a0da05927 (diff)
downloadangular.js-c30807d1413ea9942bcb065a02997082bf4291aa.tar.bz2
Change angular-mocks to throw errors on unexpected gets in the format JSTD now expects
Diffstat (limited to 'test/angular-mocks.js')
-rw-r--r--test/angular-mocks.js5
1 files changed, 4 insertions, 1 deletions
diff --git a/test/angular-mocks.js b/test/angular-mocks.js
index 7444e816..a8f189cb 100644
--- a/test/angular-mocks.js
+++ b/test/angular-mocks.js
@@ -75,7 +75,10 @@ function MockBrowser() {
var expect = expectations[method] || {};
var response = expect[url];
if (!response) {
- throw "Unexepected request for method '" + method + "' and url '" + url + "'.";
+ throw {
+ message: "Unexpected request for method '" + method + "' and url '" + url + "'.",
+ name: "Unexpected Request"
+ };
}
requests.push(function(){
callback(response.code, response.response);