Skip to content

Commit

Permalink
[UnifiedFieldList] Update tests
Browse files Browse the repository at this point in the history
  • Loading branch information
jughosta committed Jan 4, 2023
1 parent b91d24d commit 62302ce
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
1 change: 1 addition & 0 deletions test/functional/apps/discover/group1/_sidebar.ts
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) {
await kibanaServer.importExport.unload('test/functional/fixtures/kbn_archiver/discover');
await kibanaServer.savedObjects.cleanStandardList();
await kibanaServer.uiSettings.replace({});
await PageObjects.discover.cleanSidebarLocalStorage();
});

describe('field filtering', function () {
Expand Down
4 changes: 4 additions & 0 deletions test/functional/page_objects/discover_page.ts
Original file line number Diff line number Diff line change
Expand Up @@ -463,6 +463,10 @@ export class DiscoverPageObject extends FtrService {
).getAttribute('innerText');
}

public async cleanSidebarLocalStorage(): Promise<void> {
await this.browser.setLocalStorageItem('discover.unifiedFieldList.initiallyOpenSections', '{}');
}

public async waitUntilSidebarHasLoaded() {
await this.retry.waitFor('sidebar is loaded', async () => {
return (await this.getSidebarAriaDescription()).length > 0;
Expand Down

0 comments on commit 62302ce

Please sign in to comment.