forked from elastic/kibana
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[DOCS] Automate screenshot for Amazon bedrock connector (elastic#169463)
- Loading branch information
Showing
5 changed files
with
40 additions
and
2 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
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
37 changes: 37 additions & 0 deletions
37
x-pack/test/screenshot_creation/apps/response_ops_docs/stack_connectors/bedrock_connector.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,37 @@ | ||
/* | ||
* 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 ({ getService, getPageObjects }: FtrProviderContext) { | ||
const commonScreenshots = getService('commonScreenshots'); | ||
const screenshotDirectories = ['response_ops_docs', 'stack_connectors']; | ||
const pageObjects = getPageObjects(['common', 'header']); | ||
const actions = getService('actions'); | ||
const testSubjects = getService('testSubjects'); | ||
|
||
describe('Amazon bedrock connector', function () { | ||
it('Amazon bedrock connector screenshots', async () => { | ||
await pageObjects.common.navigateToApp('connectors'); | ||
await pageObjects.header.waitUntilLoadingHasFinished(); | ||
await actions.common.openNewConnectorForm('bedrock'); | ||
await testSubjects.setValue('nameInput', 'Bedrock test connector'); | ||
await testSubjects.setValue('secrets.accessKey-input', 'testkey'); | ||
await testSubjects.setValue('secrets.secret-input', 'testsecret'); | ||
await commonScreenshots.takeScreenshot( | ||
'bedrock-connector', | ||
screenshotDirectories, | ||
1920, | ||
1200 | ||
); | ||
await testSubjects.click('create-connector-flyout-save-test-btn'); | ||
await testSubjects.click('toastCloseButton'); | ||
await commonScreenshots.takeScreenshot('bedrock-params', screenshotDirectories); | ||
await testSubjects.click('euiFlyoutCloseButton'); | ||
}); | ||
}); | ||
} |
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