Merge branch 'issue1010' of https://github.com/bodawei/jasmine into bodawei-issue1010

- Merges #1011
- Fixes #1010
This commit is contained in:
Gregg Van Hove
2016-02-16 15:40:26 -08:00
3 changed files with 21 additions and 2 deletions

View File

@@ -49,7 +49,7 @@ getJasmineRequireObj().SpyRegistry = function(j$) {
this.clearSpies = function() {
var spies = currentSpies();
for (var i = 0; i < spies.length; i++) {
for (var i = spies.length - 1; i >= 0; i--) {
var spyEntry = spies[i];
spyEntry.baseObj[spyEntry.methodName] = spyEntry.originalValue;
}