mirror of
https://github.com/elastic/kibana.git
synced 2025-04-24 17:59:23 -04:00
increase timeout setting for the test
This commit is contained in:
parent
1887300f0f
commit
2e892057fb
3 changed files with 9 additions and 8 deletions
|
@ -98,9 +98,10 @@ export class FixturePlugin implements Plugin<void, void, FixtureSetupDeps, Fixtu
|
|||
transaction?.end();
|
||||
subscription.unsubscribe();
|
||||
});
|
||||
await ctx.core.elasticsearch.client.asInternalUser.ping();
|
||||
// eslint-disable-next-line no-console
|
||||
console.log('>>> in handler', apmAgent.isStarted(), apmAgent.currentTraceIds);
|
||||
await ctx.core.elasticsearch.client.asInternalUser.ping();
|
||||
|
||||
return res.ok({
|
||||
body: {
|
||||
traceId: apmAgent.currentTraceIds['trace.id'],
|
||||
|
|
|
@ -40,7 +40,7 @@ export async function assertLogContains({
|
|||
retry: RetryService;
|
||||
}): Promise<void> {
|
||||
// logs are written to disk asynchronously. I sacrificed performance to reduce flakiness.
|
||||
await retry.waitFor(description, async () => {
|
||||
await retry.waitForWithTimeout(description, 60_000, async () => {
|
||||
const logsStr = await Fs.readFile(logFilePath, 'utf-8');
|
||||
const normalizedRecords = logsStr
|
||||
.split(endOfLine)
|
||||
|
|
|
@ -17,16 +17,16 @@ export default function ({ getService }: FtrProviderContext) {
|
|||
const response1 = await supertest.get('/emit_log_with_trace_id');
|
||||
expect(response1.body.traceId).to.be.a('string');
|
||||
|
||||
await assertLogContains({
|
||||
description: 'traceId included in the Kibana logs',
|
||||
predicate: (record) => record.trace?.id === response1.body.traceId,
|
||||
retry,
|
||||
});
|
||||
|
||||
const response2 = await supertest.get('/emit_log_with_trace_id');
|
||||
expect(response1.body.traceId).to.be.a('string');
|
||||
|
||||
expect(response2.body.traceId).not.to.be(response1.body.traceId);
|
||||
|
||||
await assertLogContains({
|
||||
description: `traceId ${response1.body.traceId} included in the Kibana logs`,
|
||||
predicate: (record) => record.trace?.id === response1.body.traceId,
|
||||
retry,
|
||||
});
|
||||
});
|
||||
});
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue