2021-09-07 13:07:16 +02:00
|
|
|
/*
|
|
|
|
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
|
|
|
|
* or more contributor license agreements. Licensed under the Elastic License
|
|
|
|
* 2.0; you may not use this file except in compliance with the Elastic License
|
|
|
|
* 2.0.
|
|
|
|
*/
|
|
|
|
|
|
|
|
import { readFileSync } from 'fs';
|
|
|
|
import { resolve } from 'path';
|
|
|
|
import { CA_CERT_PATH } from '@kbn/dev-utils';
|
|
|
|
import { FtrConfigProviderContext } from '@kbn/test';
|
|
|
|
|
|
|
|
export default async function ({ readConfigFile }: FtrConfigProviderContext) {
|
|
|
|
const xpackFunctionalConfig = await readConfigFile(require.resolve('../functional/config.js'));
|
|
|
|
|
|
|
|
const servers = {
|
|
|
|
...xpackFunctionalConfig.get('servers'),
|
|
|
|
elasticsearch: {
|
|
|
|
...xpackFunctionalConfig.get('servers.elasticsearch'),
|
|
|
|
protocol: 'https',
|
|
|
|
certificateAuthorities: [readFileSync(CA_CERT_PATH)],
|
|
|
|
},
|
|
|
|
};
|
|
|
|
|
|
|
|
return {
|
|
|
|
// default to the xpack functional config
|
|
|
|
...xpackFunctionalConfig.getAll(),
|
|
|
|
servers,
|
|
|
|
esTestCluster: {
|
|
|
|
...xpackFunctionalConfig.get('esTestCluster'),
|
|
|
|
ssl: true,
|
|
|
|
},
|
|
|
|
kbnTestServer: {
|
|
|
|
...xpackFunctionalConfig.get('kbnTestServer'),
|
|
|
|
serverArgs: [
|
|
|
|
...xpackFunctionalConfig.get('kbnTestServer.serverArgs'),
|
|
|
|
`--elasticsearch.hosts=https://${servers.elasticsearch.hostname}:${servers.elasticsearch.port}`,
|
|
|
|
`--elasticsearch.ssl.certificateAuthorities=${CA_CERT_PATH}`,
|
|
|
|
],
|
|
|
|
},
|
2021-10-21 12:07:43 +02:00
|
|
|
uiSettings: {
|
|
|
|
defaults: {
|
|
|
|
'dateFormat:tz': 'UTC',
|
|
|
|
},
|
|
|
|
},
|
2021-09-07 13:07:16 +02:00
|
|
|
testFiles: [resolve(__dirname, './apps/observability')],
|
|
|
|
junit: {
|
|
|
|
...xpackFunctionalConfig.get('junit'),
|
|
|
|
reportName: 'Chrome X-Pack Observability UI Functional Tests',
|
|
|
|
},
|
|
|
|
};
|
|
|
|
}
|