Skip to content

Commit 50fdc1e

Browse files
committed
updated jest-cli package
1 parent aa84048 commit 50fdc1e

File tree

3 files changed

+564
-842
lines changed

3 files changed

+564
-842
lines changed

app/javascript/spec/breadcrumbs/on-click-functions.spec.js

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,16 @@ describe('Breadcrumbs onClick functions', () => {
6565
});
6666

6767
describe('onClickToExplorer', () => {
68+
const realLocation = window.location;
69+
70+
beforeAll(() => {
71+
delete window.location;
72+
window.location = { ...realLocation, assign: jest.fn() };
73+
});
74+
afterAll(() => {
75+
window.location = realLocation;
76+
});
77+
6878
it('calls prevent default', () => {
6979
window.miqCheckForChanges = () => false;
7080

@@ -75,7 +85,6 @@ describe('Breadcrumbs onClick functions', () => {
7585

7686
it('calls location assign', () => {
7787
window.miqCheckForChanges = () => true;
78-
window.location.assign = jest.fn();
7988

8089
onClickToExplorer(event, 'pxe', 'explorer');
8190

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@
151151
"imports-loader": "~0.8.0",
152152
"jasmine-jquery": "~2.1.1",
153153
"jest": "~26.6.3",
154-
"jest-cli": "~24.9.0",
154+
"jest-cli": "~25.5.4",
155155
"js-yaml": "~3.13.1",
156156
"ng-annotate-loader": "~0.7.0",
157157
"node-fetch": "~2.6.1",

0 commit comments

Comments
 (0)