Skip to content

Commit

Permalink
fix snapshots
Browse files Browse the repository at this point in the history
  • Loading branch information
legrego committed Oct 2, 2020
1 parent 560c10b commit f6da6b2
Showing 1 changed file with 22 additions and 20 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -195,16 +195,17 @@ describe('InsecureClusterService', () => {
expect(coreStart.http.get).toHaveBeenCalledTimes(1);
expect(coreStart.notifications.toasts.addWarning).toHaveBeenCalledTimes(1);
expect(coreStart.notifications.toasts.addWarning.mock.calls[0]).toMatchInlineSnapshot(`
Array [
Object {
"text": "mocked default alert text",
"title": "mocked default alert title",
},
Object {
"toastLifeTimeMs": 864000000,
},
]
`);
Array [
Object {
"iconType": "alert",
"text": "mocked default alert text",
"title": "mocked default alert title",
},
Object {
"toastLifeTimeMs": 864000000,
},
]
`);

expect(coreStart.notifications.toasts.remove).not.toHaveBeenCalled();
expect(storage.setItem).not.toHaveBeenCalled();
Expand Down Expand Up @@ -271,16 +272,17 @@ describe('InsecureClusterService', () => {
expect(coreStart.http.get).toHaveBeenCalledTimes(1);
expect(coreStart.notifications.toasts.addWarning).toHaveBeenCalledTimes(1);
expect(coreStart.notifications.toasts.addWarning.mock.calls[0]).toMatchInlineSnapshot(`
Array [
Object {
"text": "some new alert text",
"title": "some new title",
},
Object {
"toastLifeTimeMs": 864000000,
},
]
`);
Array [
Object {
"iconType": "alert",
"text": "some new alert text",
"title": "some new title",
},
Object {
"toastLifeTimeMs": 864000000,
},
]
`);

expect(coreStart.notifications.toasts.remove).not.toHaveBeenCalled();
expect(storage.setItem).not.toHaveBeenCalled();
Expand Down

0 comments on commit f6da6b2

Please sign in to comment.