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

Commit 07ef166

Browse files
matskomhevery
authored andcommitted
fix(ngMock): ensure mocked window still provides window.location functionality
1 parent cec4ce2 commit 07ef166

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/ngMock/angular-mocks.js

+1
Original file line numberDiff line numberDiff line change
@@ -640,6 +640,7 @@ angular.mock.createMockWindow = function() {
640640
var mockWindow = {};
641641
var setTimeoutQueue = [];
642642

643+
mockWindow.location = window.location;
643644
mockWindow.document = window.document;
644645
mockWindow.getComputedStyle = angular.bind(window, window.getComputedStyle);
645646
mockWindow.scrollTo = angular.bind(window, window.scrollTo);

0 commit comments

Comments
 (0)