mirror of
https://github.com/nasa/openmct.git
synced 2025-01-17 10:20:27 +00:00
fix(e2e): fix grand search test
This commit is contained in:
parent
b41c98d4ab
commit
724ec423d1
@ -77,11 +77,11 @@ test.describe('Grand Search', () => {
|
||||
|
||||
// Click [aria-label="OpenMCT Search"] a >> nth=0
|
||||
await page.locator('[aria-label="Search Result"] >> nth=0').click();
|
||||
await expect(page.locator('[aria-label="Search Result"] >> nth=0')).toBeHidden();
|
||||
await expect(page.locator('[aria-label="Search Result"] >> nth=0')).toBeInViewport();
|
||||
|
||||
// Fill [aria-label="OpenMCT Search"] input[type="search"]
|
||||
await page.locator('[aria-label="OpenMCT Search"] input[type="search"]').fill('foo');
|
||||
await expect(page.locator('[aria-label="Search Result"] >> nth=0')).toBeHidden();
|
||||
await expect(page.locator('[aria-label="Search Result"] >> nth=0')).not.toBeInViewport();
|
||||
|
||||
// Click text=Snapshot Save and Finish Editing Save and Continue Editing >> button >> nth=1
|
||||
await page
|
||||
|
@ -27,7 +27,7 @@
|
||||
v-if="dismissable"
|
||||
aria-label="Close"
|
||||
class="c-click-icon c-overlay__close-button icon-x"
|
||||
@click="destroy"
|
||||
@click.stop="destroy"
|
||||
></button>
|
||||
<div
|
||||
ref="element"
|
||||
@ -71,16 +71,16 @@ export default {
|
||||
});
|
||||
},
|
||||
methods: {
|
||||
destroy: function () {
|
||||
destroy() {
|
||||
if (this.dismissable) {
|
||||
this.dismiss();
|
||||
}
|
||||
},
|
||||
buttonClickHandler: function (method) {
|
||||
buttonClickHandler(method) {
|
||||
method();
|
||||
this.$emit('destroy');
|
||||
},
|
||||
getElementForFocus: function () {
|
||||
getElementForFocus() {
|
||||
const defaultElement = this.$refs.element;
|
||||
if (!this.$refs.buttons) {
|
||||
return defaultElement;
|
||||
|
Loading…
Reference in New Issue
Block a user