kibana/x-pack/tasks/test.ts
Spencer 03dad2827e
run mocha tests from x-pack with root mocha script (#51352)
* run mocha tests from x-pack with root mocha script

* Only run Karma tests in xpack intake job

* disable failing suites

* fix typo

* skip correct suite (there are multiple root suites)

* support disabling junit reporting with $DISABLE_JUNIT_REPORTER

* don't generate junit in ispec_plugin tests
2019-11-25 11:39:20 -07:00

31 lines
951 B
TypeScript

/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Elastic License;
* you may not use this file except in compliance with the Elastic License.
*/
import pluginHelpers from '@kbn/plugin-helpers';
import gulp from 'gulp';
import { getEnabledPlugins } from './helpers/flags';
export const testServerTask = async () => {
throw new Error('server mocha tests are now included in the `node scripts/mocha` script');
};
export const testBrowserTask = async () => {
const plugins = await getEnabledPlugins();
await pluginHelpers.run('testBrowser', {
plugins: plugins.join(','),
});
};
export const testBrowserDevTask = async () => {
const plugins = await getEnabledPlugins();
await pluginHelpers.run('testBrowser', {
dev: true,
plugins: plugins.join(','),
});
};
export const testTask = gulp.series(testBrowserTask, testServerTask);