Skip to content

Commit

Permalink
corrected stubs in tests
Browse files Browse the repository at this point in the history
  • Loading branch information
gmmorris committed Apr 7, 2020
1 parent 62ad819 commit 5ff0200
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 8 deletions.
12 changes: 6 additions & 6 deletions x-pack/plugins/alerting/server/routes/health.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ describe('healthRoute', () => {
expect(await handler(context, req, res)).toMatchInlineSnapshot(`
Object {
"body": Object {
"isESOUsingEphemeralEncryptionKey": true,
"hasPermanentEncryptionKey": false,
"isSufficientlySecure": true,
},
}
Expand All @@ -104,7 +104,7 @@ describe('healthRoute', () => {
expect(await handler(context, req, res)).toMatchInlineSnapshot(`
Object {
"body": Object {
"isESOUsingEphemeralEncryptionKey": false,
"hasPermanentEncryptionKey": true,
"isSufficientlySecure": true,
},
}
Expand All @@ -128,7 +128,7 @@ describe('healthRoute', () => {
expect(await handler(context, req, res)).toMatchInlineSnapshot(`
Object {
"body": Object {
"isESOUsingEphemeralEncryptionKey": false,
"hasPermanentEncryptionKey": true,
"isSufficientlySecure": true,
},
}
Expand All @@ -154,7 +154,7 @@ describe('healthRoute', () => {
expect(await handler(context, req, res)).toMatchInlineSnapshot(`
Object {
"body": Object {
"isESOUsingEphemeralEncryptionKey": false,
"hasPermanentEncryptionKey": true,
"isSufficientlySecure": false,
},
}
Expand All @@ -180,7 +180,7 @@ describe('healthRoute', () => {
expect(await handler(context, req, res)).toMatchInlineSnapshot(`
Object {
"body": Object {
"isESOUsingEphemeralEncryptionKey": false,
"hasPermanentEncryptionKey": true,
"isSufficientlySecure": false,
},
}
Expand All @@ -206,7 +206,7 @@ describe('healthRoute', () => {
expect(await handler(context, req, res)).toMatchInlineSnapshot(`
Object {
"body": Object {
"isESOUsingEphemeralEncryptionKey": false,
"hasPermanentEncryptionKey": true,
"isSufficientlySecure": true,
},
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,10 @@ describe('alert_add', () => {
docLinks: { ELASTIC_WEBSITE_URL: '', DOC_LINK_VERSION: '' },
};

mockes.http.get.mockResolvedValue({ isSufficientlySecure: true });
mockes.http.get.mockResolvedValue({
isSufficientlySecure: true,
hasPermanentEncryptionKey: true,
});

const alertType = {
id: 'my-alert-type',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,10 @@ describe('alert_edit', () => {
docLinks: { ELASTIC_WEBSITE_URL: '', DOC_LINK_VERSION: '' },
};

mockedCoreSetup.http.get.mockResolvedValue({ isSufficientlySecure: true });
mockedCoreSetup.http.get.mockResolvedValue({
isSufficientlySecure: true,
hasPermanentEncryptionKey: true,
});

const alertType = {
id: 'my-alert-type',
Expand Down

0 comments on commit 5ff0200

Please sign in to comment.