Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Discover] Unskip main functional tests #84300

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 9 additions & 7 deletions test/functional/apps/discover/_discover.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,7 @@ export default function ({ getService, getPageObjects }) {
defaultIndex: 'logstash-*',
};

// Failing: See https://github.com/elastic/kibana/issues/82915
describe.skip('discover test', function describeIndexTests() {
describe('discover test', function describeIndexTests() {
before(async function () {
log.debug('load kibana index with default index pattern');
await esArchiver.load('discover');
Expand Down Expand Up @@ -315,10 +314,13 @@ export default function ({ getService, getPageObjects }) {

const getRequestTimestamp = async () => {
const requestStats = await inspector.getTableData();
const requestTimestamp = requestStats.filter((r) =>
r[0].includes('Request timestamp')
)[0][1];
return requestTimestamp;
const requestStatsRow = requestStats.filter(
(r) => r && r[0] && r[0].includes('Request timestamp')
);
if (!requestStatsRow || !requestStatsRow[0] || !requestStatsRow[0][1]) {
return '';
}
return requestStatsRow[0][1];
};

const requestTimestampBefore = await getRequestTimestamp();
Expand All @@ -327,7 +329,7 @@ export default function ({ getService, getPageObjects }) {
log.debug(
`Timestamp before: ${requestTimestampBefore}, Timestamp after: ${requestTimestampAfter}`
);
return requestTimestampBefore !== requestTimestampAfter;
return requestTimestampAfter && requestTimestampBefore !== requestTimestampAfter;
});
});

Expand Down