Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

Commit 854bf5b

Browse files
sagens42tbosch
authored andcommitted
feat(ngMock): add support of mocha tdd interface
Closes #7489
1 parent 9fb0e16 commit 854bf5b

File tree

2 files changed

+3
-5
lines changed

2 files changed

+3
-5
lines changed

src/ngMock/.jshintrc

+1-3
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,6 @@
1818
"browser": true,
1919
"globals": {
2020
"angular": false,
21-
"expect": false,
22-
"beforeEach": false,
23-
"afterEach": false
21+
"expect": false
2422
}
2523
}

src/ngMock/angular-mocks.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -1976,11 +1976,11 @@ if(window.jasmine || window.mocha) {
19761976
};
19771977

19781978

1979-
beforeEach(function() {
1979+
(window.beforeEach || window.setup)(function() {
19801980
currentSpec = this;
19811981
});
19821982

1983-
afterEach(function() {
1983+
(window.afterEach || window.teardown)(function() {
19841984
var injector = currentSpec.$injector;
19851985

19861986
currentSpec.$injector = null;

0 commit comments

Comments
 (0)