-
Notifications
You must be signed in to change notification settings - Fork 8.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into dev/fix-drildowns-welcome-in-ie
- Loading branch information
Showing
15 changed files
with
186 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 2 additions & 0 deletions
2
...time/public/components/certificates/__tests__/__snapshots__/fingerprint_col.test.tsx.snap
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 2 additions & 0 deletions
2
...ublic/components/overview/monitor_list/__tests__/__snapshots__/monitor_list.test.tsx.snap
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
24 changes: 24 additions & 0 deletions
24
x-pack/plugins/uptime/public/components/settings/translations.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
/* | ||
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one | ||
* or more contributor license agreements. Licensed under the Elastic License; | ||
* you may not use this file except in compliance with the Elastic License. | ||
*/ | ||
|
||
import { i18n } from '@kbn/i18n'; | ||
|
||
export const certificateFormTranslations = { | ||
ageInputAriaLabel: i18n.translate( | ||
'xpack.uptime.sourceConfiguration.ageLimitThresholdInput.ariaLabel', | ||
{ | ||
defaultMessage: | ||
'An input that controls the maximum number of days for which a TLS certificate may be valid before Kibana will show a warning.', | ||
} | ||
), | ||
expirationInputAriaLabel: i18n.translate( | ||
'xpack.uptime.sourceConfiguration.certificateExpirationThresholdInput.ariaLabel', | ||
{ | ||
defaultMessage: | ||
'An input that controls the minimum number of days remaining for TLS certificate expiration before Kibana will show a warning.', | ||
} | ||
), | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,86 @@ | ||
/* | ||
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one | ||
* or more contributor license agreements. Licensed under the Elastic License; | ||
* you may not use this file except in compliance with the Elastic License. | ||
*/ | ||
|
||
import moment from 'moment'; | ||
import { FtrProviderContext } from '../ftr_provider_context'; | ||
import { makeChecks } from '../../api_integration/apis/uptime/rest/helper/make_checks'; | ||
|
||
const A11Y_TEST_MONITOR_ID = 'a11yTestMonitor'; | ||
|
||
export default function({ getService, getPageObjects }: FtrProviderContext) { | ||
const { uptime } = getPageObjects(['common', 'uptime']); | ||
const a11y = getService('a11y'); | ||
const uptimeService = getService('uptime'); | ||
const esArchiver = getService('esArchiver'); | ||
const es = getService('es'); | ||
|
||
describe('uptime', () => { | ||
before(async () => { | ||
await esArchiver.load('uptime/blank'); | ||
await makeChecks(es, A11Y_TEST_MONITOR_ID, 150, 1, 1000, { | ||
tls: { | ||
certificate_not_valid_after: moment() | ||
.add(30, 'days') | ||
.toISOString(), | ||
certificate_not_valid_before: moment() | ||
.subtract(90, 'days') | ||
.toISOString(), | ||
server: { | ||
x509: { | ||
subject: { | ||
common_name: 'a11y_common_name', | ||
}, | ||
issuer: { | ||
common_name: 'a11y_issuer_name', | ||
}, | ||
}, | ||
}, | ||
}, | ||
}); | ||
}); | ||
|
||
beforeEach(async () => { | ||
await uptime.goToRoot(); | ||
}); | ||
|
||
after(async () => { | ||
await esArchiver.unload('uptime/blank'); | ||
}); | ||
|
||
it('overview page', async () => { | ||
await a11y.testAppSnapshot(); | ||
}); | ||
|
||
it('overview page with expanded monitor detail', async () => { | ||
await uptimeService.overview.expandMonitorDetail(A11Y_TEST_MONITOR_ID); | ||
await uptimeService.overview.openIntegrationsPopoverForMonitor(A11Y_TEST_MONITOR_ID); | ||
await a11y.testAppSnapshot(); | ||
}); | ||
|
||
it('overview alert popover controls', async () => { | ||
await uptimeService.overview.openAlertsPopover(); | ||
await a11y.testAppSnapshot(); | ||
await uptimeService.overview.navigateToNestedPopover(); | ||
await a11y.testAppSnapshot(); | ||
}); | ||
|
||
it('detail page', async () => { | ||
await uptimeService.navigation.goToMonitor(A11Y_TEST_MONITOR_ID); | ||
await uptimeService.monitor.locationMapIsRendered(); | ||
await a11y.testAppSnapshot(); | ||
}); | ||
|
||
it('settings page', async () => { | ||
await uptimeService.navigation.goToSettings(); | ||
await a11y.testAppSnapshot(); | ||
}); | ||
|
||
it('certificates page', async () => { | ||
await uptimeService.navigation.goToCertificates(); | ||
await a11y.testAppSnapshot(); | ||
}); | ||
}); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
/* | ||
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one | ||
* or more contributor license agreements. Licensed under the Elastic License; | ||
* you may not use this file except in compliance with the Elastic License. | ||
*/ | ||
|
||
import { FtrProviderContext } from '../../ftr_provider_context'; | ||
|
||
export function UptimeOverviewProvider({ getService }: FtrProviderContext) { | ||
const testSubjects = getService('testSubjects'); | ||
|
||
return { | ||
async expandMonitorDetail(id: string): Promise<void> { | ||
return testSubjects.click(`xpack.uptime.monitorList.${id}.expandMonitorDetail`); | ||
}, | ||
async openIntegrationsPopoverForMonitor(id: string): Promise<void> { | ||
return testSubjects.click(`xpack.uptime.monitorList.actionsPopover.${id}`); | ||
}, | ||
async openAlertsPopover(): Promise<void> { | ||
return testSubjects.click('xpack.uptime.alertsPopover.toggleButton'); | ||
}, | ||
/** | ||
* If the popover is already open, click the nested button. | ||
* Otherwise, open the popover, then click the nested button. | ||
*/ | ||
async navigateToNestedPopover(): Promise<void> { | ||
if (testSubjects.exists('xpack.uptime.openAlertContextPanel')) { | ||
return testSubjects.click('xpack.uptime.openAlertContextPanel'); | ||
} | ||
await testSubjects.click('xpack.uptime.alertsPopover.toggleButton'); | ||
return testSubjects.click('xpack.uptime.openAlertContextPanel'); | ||
}, | ||
}; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters