diff --git a/x-pack/test/functional_execution_context/tests/browser.ts b/x-pack/test/functional_execution_context/tests/browser.ts index f6e46a6bc2280..8fa1103fbe852 100644 --- a/x-pack/test/functional_execution_context/tests/browser.ts +++ b/x-pack/test/functional_execution_context/tests/browser.ts @@ -9,7 +9,7 @@ import type { FtrProviderContext } from '../ftr_provider_context'; import { assertLogContains, isExecutionContextLog } from '../test_utils'; export default function ({ getService, getPageObjects }: FtrProviderContext) { - const PageObjects = getPageObjects(['common', 'dashboard', 'header', 'home']); + const PageObjects = getPageObjects(['common', 'dashboard', 'header', 'home', 'timePicker']); const retry = getService('retry'); // Failing: See https://github.com/elastic/kibana/issues/112102 @@ -33,15 +33,18 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { describe('discover app', () => { before(async () => { await PageObjects.common.navigateToApp('discover'); + await PageObjects.timePicker.setCommonlyUsedTime('Last_7 days'); await PageObjects.header.waitUntilLoadingHasFinished(); }); - it('propagates context for Discover', async () => { - await assertLogContains({ - description: 'execution context propagates to Elasticsearch via "x-opaque-id" header', - predicate: (record) => - Boolean(record.http?.request?.id?.includes('kibana:application:discover')), - retry, + describe('propagates context for Discover', () => { + it('propagates to Elasticsearch via "x-opaque-id" header', async () => { + await assertLogContains({ + description: 'execution context propagates to Elasticsearch via "x-opaque-id" header', + predicate: (record) => + Boolean(record.http?.request?.id?.includes('kibana:application:discover')), + retry, + }); }); await assertLogContains({ @@ -77,6 +80,7 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { before(async () => { await PageObjects.common.navigateToApp('dashboard'); await PageObjects.dashboard.loadSavedDashboard('[Flights] Global Flight Dashboard'); + await PageObjects.timePicker.setCommonlyUsedTime('Last_7 days'); await PageObjects.dashboard.waitForRenderComplete(); await PageObjects.header.waitUntilLoadingHasFinished(); });