Skip to content
This repository has been archived by the owner on Aug 30, 2021. It is now read-only.

Commit

Permalink
FIxing Jasmine tests to fit new version
Browse files Browse the repository at this point in the history
  • Loading branch information
amoshaviv committed Mar 5, 2014
1 parent f077caf commit 584ccf1
Showing 1 changed file with 12 additions and 6 deletions.
18 changes: 12 additions & 6 deletions public/modules/articles/tests/articles.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,18 @@
// When the toEqualData matcher compares two objects, it takes only object properties into
// account and ignores methods.
beforeEach(function() {
this.addMatchers({
toEqualData: function(expected) {
return angular.equals(this.actual, expected);
}
});
});
jasmine.addMatchers({
toEqualData: function(util, customEqualityTesters) {
return {
compare: function(actual, expected) {
return {
pass: angular.equals(actual, expected)
};
}
};
}
});
});

// Then we can start by loading the main application module
beforeEach(module('mean'));
Expand Down

0 comments on commit 584ccf1

Please sign in to comment.