forked from elastic/kibana
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[8.12] [RAM][[Maintenance Window][DOCS] Maintenance window scoped que…
…ry automated screenshots (elastic#174315) (elastic#174872) # Backport This will backport the following commits from `main` to `8.12`: - [[RAM][[Maintenance Window][DOCS] Maintenance window scoped query automated screenshots (elastic#174315)](elastic#174315) <!--- Backport version: 8.9.8 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sqren/backport) <!--BACKPORT [{"author":{"name":"Lisa Cawley","email":"[email protected]"},"sourceCommit":{"committedDate":"2024-01-15T21:22:33Z","message":"[RAM][[Maintenance Window][DOCS] Maintenance window scoped query automated screenshots (elastic#174315)","sha":"02ea9192f7181e7054266462be1273ab1431abaf","branchLabelMapping":{"^v8.13.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","Team:ResponseOps","docs","Feature:Alerting/RulesManagement","v8.12.1","v8.13.0"],"number":174315,"url":"https://github.com/elastic/kibana/pull/174315","mergeCommit":{"message":"[RAM][[Maintenance Window][DOCS] Maintenance window scoped query automated screenshots (elastic#174315)","sha":"02ea9192f7181e7054266462be1273ab1431abaf"}},"sourceBranch":"main","suggestedTargetBranches":["8.12"],"targetPullRequestStates":[{"branch":"8.12","label":"v8.12.1","labelRegex":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v8.13.0","labelRegex":"^v8.13.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/174315","number":174315,"mergeCommit":{"message":"[RAM][[Maintenance Window][DOCS] Maintenance window scoped query automated screenshots (elastic#174315)","sha":"02ea9192f7181e7054266462be1273ab1431abaf"}}]}] BACKPORT-->
- Loading branch information
Showing
8 changed files
with
105 additions
and
2 deletions.
There are no files selected for viewing
Binary file added
BIN
+136 KB
docs/management/maintenance-windows/images/create-maintenance-window-filter.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+45.4 KB
(120%)
docs/management/maintenance-windows/images/create-maintenance-window.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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
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
57 changes: 57 additions & 0 deletions
57
.../observability/screenshot_creation/response_ops_docs/maintenance_windows/create_window.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,57 @@ | ||
/* | ||
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one | ||
* or more contributor license agreements. Licensed under the Elastic License | ||
* 2.0; you may not use this file except in compliance with the Elastic License | ||
* 2.0. | ||
*/ | ||
|
||
import { FtrProviderContext } from '../../../../../ftr_provider_context'; | ||
|
||
export default function ({ getPageObjects, getService }: FtrProviderContext) { | ||
const pageObjects = getPageObjects(['common', 'header', 'svlCommonPage']); | ||
const svlCommonScreenshots = getService('svlCommonScreenshots'); | ||
const screenshotDirectories = ['response_ops_docs', 'observability_maintenace_windows']; | ||
const find = getService('find'); | ||
const testSubjects = getService('testSubjects'); | ||
|
||
describe('create window', function () { | ||
beforeEach(async () => { | ||
await pageObjects.svlCommonPage.login(); | ||
}); | ||
|
||
after(async () => { | ||
await pageObjects.svlCommonPage.forceLogout(); | ||
}); | ||
|
||
it('create maintenance window screenshot', async () => { | ||
await pageObjects.common.navigateToApp('maintenanceWindows'); | ||
await pageObjects.header.waitUntilLoadingHasFinished(); | ||
const createButton = await find.byCssSelector( | ||
'[data-test-subj="mw-empty-prompt"] .euiButton' | ||
); | ||
await createButton.click(); | ||
await svlCommonScreenshots.takeScreenshot( | ||
'create-maintenance-window', | ||
screenshotDirectories, | ||
1400, | ||
1600 | ||
); | ||
const filterAlerts = await find.byCssSelector( | ||
'[data-test-subj="maintenanceWindowScopedQuerySwitch"] .euiSwitch__button' | ||
); | ||
await filterAlerts.click(); | ||
const radioGroup = await testSubjects.find('maintenanceWindowCategorySelectionRadioGroup'); | ||
const label = await radioGroup.findByCssSelector(`label[for="observability"]`); | ||
await label.click(); | ||
await testSubjects.setValue('queryInput', 'kibana.alert.rule.name: custom-threshold-rule-1'); | ||
await svlCommonScreenshots.takeScreenshot( | ||
'create-maintenance-window-filter', | ||
screenshotDirectories, | ||
1400, | ||
1600 | ||
); | ||
const cancelButton = await testSubjects.find('cancelMaintenanceWindow'); | ||
await cancelButton.click(); | ||
}); | ||
}); | ||
} |
20 changes: 20 additions & 0 deletions
20
...t_suites/observability/screenshot_creation/response_ops_docs/maintenance_windows/index.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,20 @@ | ||
/* | ||
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one | ||
* or more contributor license agreements. Licensed under the Elastic License | ||
* 2.0; you may not use this file except in compliance with the Elastic License | ||
* 2.0. | ||
*/ | ||
|
||
import { FtrProviderContext } from '../../../../../ftr_provider_context'; | ||
|
||
export default function ({ loadTestFile, getService }: FtrProviderContext) { | ||
const browser = getService('browser'); | ||
|
||
describe('observability maintenance windows', function () { | ||
before(async () => { | ||
await browser.setWindowSize(1920, 1080); | ||
}); | ||
|
||
loadTestFile(require.resolve('./create_window')); | ||
}); | ||
} |