mirror of
https://github.com/elastic/kibana.git
synced 2025-04-24 01:38:56 -04:00
chore(NA): remove mocha junit ci integrations (#88129)
* chore(NA): remove mocha junit ci integrations * chore(NA): remove mocha script from xpack * chore(NA): single rule exclusion on eslint config for mocha * chore(NA): remove unused custom mocha integration code from kbn/test * chore(NA): rewording packages readme * docs(NA): remoe mocha mention from development-unit-tests
This commit is contained in:
parent
bb70c6a82a
commit
9139ab15fd
25 changed files with 26 additions and 306 deletions
|
@ -5,11 +5,10 @@ kibanaLibrary.load()
|
|||
|
||||
def CI_GROUP_PARAM = params.CI_GROUP
|
||||
|
||||
// Looks like 'oss:ciGroup:1', 'oss:firefoxSmoke', or 'all:serverMocha'
|
||||
// Looks like 'oss:ciGroup:1', 'oss:firefoxSmoke'
|
||||
def JOB_PARTS = CI_GROUP_PARAM.split(':')
|
||||
def IS_XPACK = JOB_PARTS[0] == 'xpack'
|
||||
def JOB = JOB_PARTS[1]
|
||||
def NEED_BUILD = JOB != 'serverMocha'
|
||||
def CI_GROUP = JOB_PARTS.size() > 2 ? JOB_PARTS[2] : ''
|
||||
def EXECUTIONS = params.NUMBER_EXECUTIONS.toInteger()
|
||||
def AGENT_COUNT = getAgentCount(EXECUTIONS)
|
||||
|
@ -31,15 +30,13 @@ kibanaPipeline(timeoutMinutes: 180) {
|
|||
print "Agent ${agentNumberInside} - ${agentExecutions} executions"
|
||||
|
||||
workers.functional('flaky-test-runner', {
|
||||
if (NEED_BUILD) {
|
||||
if (!IS_XPACK) {
|
||||
kibanaPipeline.buildOss()
|
||||
if (CI_GROUP == '1') {
|
||||
runbld("./test/scripts/jenkins_build_kbn_sample_panel_action.sh", "Build kbn tp sample panel action for ciGroup1")
|
||||
}
|
||||
} else {
|
||||
kibanaPipeline.buildXpack()
|
||||
if (!IS_XPACK) {
|
||||
kibanaPipeline.buildOss()
|
||||
if (CI_GROUP == '1') {
|
||||
runbld("./test/scripts/jenkins_build_kbn_sample_panel_action.sh", "Build kbn tp sample panel action for ciGroup1")
|
||||
}
|
||||
} else {
|
||||
kibanaPipeline.buildXpack()
|
||||
}
|
||||
}, getWorkerMap(agentNumberInside, agentExecutions, worker, workerFailures))()
|
||||
}
|
||||
|
@ -60,17 +57,7 @@ kibanaPipeline(timeoutMinutes: 180) {
|
|||
|
||||
def getWorkerFromParams(isXpack, job, ciGroup) {
|
||||
if (!isXpack) {
|
||||
if (job == 'serverMocha') {
|
||||
return kibanaPipeline.functionalTestProcess('serverMocha', {
|
||||
kibanaPipeline.bash(
|
||||
"""
|
||||
source src/dev/ci_setup/setup_env.sh
|
||||
node scripts/mocha
|
||||
""",
|
||||
"run `node scripts/mocha`"
|
||||
)
|
||||
})
|
||||
} else if (job == 'accessibility') {
|
||||
if (job == 'accessibility') {
|
||||
return kibanaPipeline.functionalTestProcess('kibana-accessibility', './test/scripts/jenkins_accessibility.sh')
|
||||
} else if (job == 'firefoxSmoke') {
|
||||
return kibanaPipeline.functionalTestProcess('firefoxSmoke', './test/scripts/jenkins_firefox_smoke.sh')
|
||||
|
|
|
@ -1,8 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
set -euo pipefail
|
||||
|
||||
source "$(dirname "${0}")/../util.sh"
|
||||
|
||||
checks-reporter-with-killswitch "Mocha Tests" \
|
||||
node scripts/mocha
|
12
.eslintrc.js
12
.eslintrc.js
|
@ -71,11 +71,6 @@ const SAFER_LODASH_SET_DEFINITELYTYPED_HEADER = `
|
|||
*/
|
||||
`;
|
||||
|
||||
const allMochaRulesOff = {};
|
||||
Object.keys(require('eslint-plugin-mocha').rules).forEach((k) => {
|
||||
allMochaRulesOff['mocha/' + k] = 'off';
|
||||
});
|
||||
|
||||
module.exports = {
|
||||
root: true,
|
||||
|
||||
|
@ -542,7 +537,6 @@ module.exports = {
|
|||
'packages/kbn-eslint-import-resolver-kibana/**/*.js',
|
||||
'packages/kbn-eslint-plugin-eslint/**/*',
|
||||
'x-pack/gulpfile.js',
|
||||
'x-pack/dev-tools/mocha/setup_mocha.js',
|
||||
'x-pack/scripts/*.js',
|
||||
],
|
||||
excludedFiles: ['**/integration_tests/**/*'],
|
||||
|
@ -574,7 +568,9 @@ module.exports = {
|
|||
*/
|
||||
{
|
||||
files: ['test/harden/*.js', 'packages/elastic-safer-lodash-set/test/*.js'],
|
||||
rules: allMochaRulesOff,
|
||||
rules: {
|
||||
'mocha/handle-done-callback': 'off',
|
||||
},
|
||||
},
|
||||
{
|
||||
files: ['**/*.{js,mjs,ts,tsx}'],
|
||||
|
@ -794,7 +790,6 @@ module.exports = {
|
|||
files: ['x-pack/plugins/security_solution/**/*.{js,mjs,ts,tsx}'],
|
||||
plugins: ['eslint-plugin-node', 'react'],
|
||||
env: {
|
||||
mocha: true,
|
||||
jest: true,
|
||||
},
|
||||
rules: {
|
||||
|
@ -930,7 +925,6 @@ module.exports = {
|
|||
files: ['x-pack/plugins/lists/**/*.{js,mjs,ts,tsx}'],
|
||||
plugins: ['eslint-plugin-node'],
|
||||
env: {
|
||||
mocha: true,
|
||||
jest: true,
|
||||
},
|
||||
rules: {
|
||||
|
|
1
.teamcity/src/builds/test/QuickTests.kt
vendored
1
.teamcity/src/builds/test/QuickTests.kt
vendored
|
@ -14,7 +14,6 @@ object QuickTests : BuildType({
|
|||
val testScripts = mapOf(
|
||||
"Test Hardening" to ".ci/teamcity/checks/test_hardening.sh",
|
||||
"Test Projects" to ".ci/teamcity/tests/test_projects.sh",
|
||||
"Mocha Tests" to ".ci/teamcity/tests/mocha.sh"
|
||||
)
|
||||
|
||||
steps {
|
||||
|
|
|
@ -17,10 +17,6 @@ root)
|
|||
|Jest (integration) |`**/integration_tests/**/*.test.{js,mjs,ts,tsx}`
|
||||
|`yarn test:jest_integration [test path]`
|
||||
|
||||
|Mocha
|
||||
|`**/__tests__/**/*.js`
|
||||
|`node scripts/mocha --grep=regexp [test path]`
|
||||
|
||||
|Functional
|
||||
|`test/**/config.js` `x-pack/test/**/config.js`
|
||||
|`node scripts/functional_tests_server --config [directory]/config.js``node scripts/functional_test_runner_ --config [directory]/config.js --grep=regexp`
|
||||
|
@ -60,8 +56,6 @@ kibana/src/plugins/dashboard/server$ yarn test:jest --coverage
|
|||
yarn jest --coverage --verbose --config /home/tyler/elastic/kibana/src/plugins/dashboard/jest.config.js server
|
||||
----
|
||||
|
||||
NOTE: There are still a handful of legacy tests that use the Mocha test runner. For those tests, use `node scripts/mocha --grep=regexp [test path]`. Tests using Mocha are located within `__tests__` directories.
|
||||
|
||||
|
||||
[discrete]
|
||||
=== Running browser automation tests
|
||||
|
|
|
@ -1,20 +1,7 @@
|
|||
[[development-unit-tests]]
|
||||
== Unit testing frameworks
|
||||
|
||||
{kib} is migrating unit testing from `Mocha` to `Jest`. Legacy unit tests
|
||||
still exist in Mocha but all new unit tests should be written in Jest.
|
||||
|
||||
[discrete]
|
||||
=== Mocha (legacy)
|
||||
|
||||
Mocha tests are contained in `__tests__` directories.
|
||||
|
||||
*Running Mocha Unit Tests*
|
||||
|
||||
["source","shell"]
|
||||
-----------
|
||||
yarn test:mocha
|
||||
-----------
|
||||
{kib} is doing unit testing doing `Jest`.
|
||||
|
||||
[discrete]
|
||||
== Jest
|
||||
|
@ -92,23 +79,10 @@ the `--debug-brk` flag. You’ll need to connect a remote debugger such
|
|||
as https://github.com/node-inspector/node-inspector[`node-inspector`]
|
||||
to proceed in this mode.
|
||||
|
||||
[source,bash]
|
||||
----
|
||||
node scripts/mocha --debug <file>
|
||||
----
|
||||
|
||||
[discrete]
|
||||
=== Unit Testing Plugins
|
||||
|
||||
This should work super if you’re using the
|
||||
Even when using
|
||||
https://github.com/elastic/kibana/tree/master/packages/kbn-plugin-generator[Kibana
|
||||
plugin generator]. If you’re not using the generator, well, you’re on
|
||||
your own. We suggest you look at how the generator works.
|
||||
|
||||
To run the tests for just your particular plugin run the following
|
||||
command from your plugin:
|
||||
|
||||
[source,bash]
|
||||
----
|
||||
yarn test:mocha
|
||||
----
|
||||
plugin generator] we do not enforce a way for unit testing your plugin. Please setup and you use
|
||||
the tools of your choice. If the plugin will live inside the Kibana repo `Jest` must be used.
|
|
@ -27,7 +27,7 @@ image::images/job_view.png[]
|
|||
[discrete]
|
||||
=== Viewing ciGroup/test Logs
|
||||
|
||||
To view the logs for a failed specific ciGroup, jest, mocha, type checkers, linters, etc., click on the *Pipeline Steps* link in from the Job page.
|
||||
To view the logs for a failed specific ciGroup, jest, type checkers, linters, etc., click on the *Pipeline Steps* link in from the Job page.
|
||||
|
||||
image::images/pipeline_steps_view.png[]
|
||||
|
||||
|
|
|
@ -42,7 +42,6 @@
|
|||
"es": "node scripts/es",
|
||||
"test:jest": "node scripts/jest",
|
||||
"test:jest_integration": "node scripts/jest_integration",
|
||||
"test:mocha": "node scripts/mocha",
|
||||
"test:ftr": "node scripts/functional_tests",
|
||||
"test:ftr:server": "node scripts/functional_tests_server",
|
||||
"test:ftr:runner": "node scripts/functional_test_runner",
|
||||
|
|
|
@ -44,23 +44,17 @@ All new packages should use the `@kbn` namespace, and should be marked with
|
|||
|
||||
## Unit tests for a package
|
||||
|
||||
Currently there are two patterns used to test packages, one using Mocha and one using Jest. These patterns emerged out of convention and we'd like to make them more similar to each other in the near future.
|
||||
Currently there is only one tool being used in order to test packages which is Jest. Below we will explain how it should be done.
|
||||
|
||||
### 1. Mocha
|
||||
Today a package can follow the pattern of having a `__tests__` directory in each source code directory of a package which contains the tests for that module. These are usually run by Mocha.
|
||||
|
||||
If a package's tests should be run with Mocha, you'll have to opt-in to run them by appending the package's test file pattern(s) to Kibana's `src/dev/mocha/run_mocha_cli.js` file. These will then be run by the unit test runner.
|
||||
|
||||
* `yarn test` or `yarn grunt test` runs all unit tests.
|
||||
* `node scripts/mocha` runs all Mocha tests.
|
||||
|
||||
### 2. Jest
|
||||
A package can also follow the pattern of having `.test.js` files as siblings of the source code files, and these run by Jest.
|
||||
### Jest
|
||||
A package should follow the pattern of having `.test.js` files as siblings of the source code files, and these run by Jest.
|
||||
|
||||
A package using the `.test.js` naming convention will have those tests automatically picked up by Jest and run by the unit test runner, currently mapped to the Kibana `test` script in the root `package.json`.
|
||||
|
||||
* `yarn test` or `yarn grunt test` runs all unit tests.
|
||||
* `yarn jest` runs all Jest tests in Kibana.
|
||||
|
||||
In order for the plugin or package to use Jest, a jest.config.js file must be present in it's root. However, there are safeguards for this in CI should a test file be added without a corresponding config file.
|
||||
|
||||
----
|
||||
Each package can also specify its own `test` script in the package's `package.json`, for cases where you'd prefer to run the tests from the local package directory.
|
||||
|
|
|
@ -63,10 +63,6 @@ Generated plugins receive a handful of scripts that can be used during developme
|
|||
|
||||
Build a distributable archive of your plugin.
|
||||
|
||||
- `yarn test:mocha`
|
||||
|
||||
Run the server tests using mocha.
|
||||
|
||||
|
||||
To start kibana run the following command from Kibana root.
|
||||
|
||||
|
|
|
@ -46,12 +46,7 @@ export { readConfigFile } from './functional_test_runner/lib/config/read_config_
|
|||
|
||||
export { runFtrCli } from './functional_test_runner/cli';
|
||||
|
||||
export {
|
||||
createAutoJUnitReporter,
|
||||
runMochaCli,
|
||||
setupJUnitReportGeneration,
|
||||
escapeCdata,
|
||||
} from './mocha';
|
||||
export { setupJUnitReportGeneration, escapeCdata } from './mocha';
|
||||
|
||||
export { runFailedTestsReporterCli } from './failed_tests_reporter';
|
||||
|
||||
|
|
|
@ -1,37 +0,0 @@
|
|||
/*
|
||||
* Licensed to Elasticsearch B.V. under one or more contributor
|
||||
* license agreements. See the NOTICE file distributed with
|
||||
* this work for additional information regarding copyright
|
||||
* ownership. Elasticsearch B.V. licenses this file to you under
|
||||
* the Apache License, Version 2.0 (the "License"); you may
|
||||
* not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing,
|
||||
* software distributed under the License is distributed on an
|
||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
* KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
|
||||
import mocha from 'mocha';
|
||||
import { setupJUnitReportGeneration } from './junit_report_generation';
|
||||
|
||||
const MochaSpecReporter = mocha.reporters.spec;
|
||||
|
||||
export function createAutoJUnitReporter(junitReportOptions) {
|
||||
return class AutoJUnitReporter {
|
||||
constructor(runner, options) {
|
||||
// setup a spec reporter for console output
|
||||
new MochaSpecReporter(runner, options);
|
||||
|
||||
// in CI we also setup the JUnit reporter
|
||||
if (process.env.CI && !process.env.DISABLE_JUNIT_REPORTER) {
|
||||
setupJUnitReportGeneration(runner, junitReportOptions);
|
||||
}
|
||||
}
|
||||
};
|
||||
}
|
|
@ -17,13 +17,9 @@
|
|||
* under the License.
|
||||
*/
|
||||
|
||||
// @ts-ignore not typed yet
|
||||
export { createAutoJUnitReporter } from './auto_junit_reporter';
|
||||
// @ts-ignore not typed yet
|
||||
export { setupJUnitReportGeneration } from './junit_report_generation';
|
||||
// @ts-ignore not typed yet
|
||||
export { runMochaCli } from './run_mocha_cli';
|
||||
// @ts-ignore not typed yet
|
||||
export { recordLog, snapshotLogsForRunnable } from './log_cache';
|
||||
// @ts-ignore not typed yet
|
||||
export { escapeCdata } from './xml';
|
||||
|
|
|
@ -1,99 +0,0 @@
|
|||
/*
|
||||
* Licensed to Elasticsearch B.V. under one or more contributor
|
||||
* license agreements. See the NOTICE file distributed with
|
||||
* this work for additional information regarding copyright
|
||||
* ownership. Elasticsearch B.V. licenses this file to you under
|
||||
* the Apache License, Version 2.0 (the "License"); you may
|
||||
* not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing,
|
||||
* software distributed under the License is distributed on an
|
||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
* KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
|
||||
import { REPO_ROOT } from '@kbn/utils';
|
||||
import getopts from 'getopts';
|
||||
import globby from 'globby';
|
||||
|
||||
export function runMochaCli() {
|
||||
const opts = getopts(process.argv.slice(2), {
|
||||
alias: {
|
||||
t: 'timeout',
|
||||
},
|
||||
boolean: ['no-timeouts'],
|
||||
});
|
||||
|
||||
const runInBand =
|
||||
process.execArgv.includes('--inspect') || process.execArgv.includes('--inspect-brk');
|
||||
|
||||
// ensure that mocha exits when test have completed
|
||||
process.argv.push('--exit');
|
||||
|
||||
// check that we aren't leaking any globals
|
||||
process.argv.push('--check-leaks');
|
||||
// prevent globals injected from canvas plugins from triggering leak check
|
||||
process.argv.push('--globals', '__core-js_shared__,core,_, ');
|
||||
|
||||
// set default test timeout
|
||||
if (opts.timeout == null && !opts['no-timeouts']) {
|
||||
if (runInBand) {
|
||||
process.argv.push('--no-timeouts');
|
||||
} else {
|
||||
process.argv.push('--timeout', '10000');
|
||||
}
|
||||
}
|
||||
|
||||
// set default slow timeout
|
||||
if (opts.slow == null) {
|
||||
process.argv.push('--slow', '5000');
|
||||
}
|
||||
|
||||
// set default reporter
|
||||
if (opts.reporter == null) {
|
||||
process.argv.push('--reporter', require.resolve('./server_junit_reporter'));
|
||||
}
|
||||
|
||||
// set default test files
|
||||
if (!opts._.length) {
|
||||
globby
|
||||
.sync(
|
||||
[
|
||||
'src/**/__tests__/**/*.{js,ts,tsx}',
|
||||
'packages/**/__tests__/**/*.{js,ts,tsx}',
|
||||
'tasks/**/__tests__/**/*.{js,ts,tsx}',
|
||||
'x-pack/common/**/__tests__/**/*.{js,ts,tsx}',
|
||||
'x-pack/server/**/__tests__/**/*.{js,ts,tsx}',
|
||||
`x-pack/legacy/plugins/*/__tests__/**/*.{js,ts,tsx}`,
|
||||
`x-pack/legacy/plugins/*/common/**/__tests__/**/*.{js,ts,tsx}`,
|
||||
`x-pack/legacy/plugins/*/**/server/**/__tests__/**/*.{js,ts,tsx}`,
|
||||
],
|
||||
{
|
||||
cwd: REPO_ROOT,
|
||||
onlyFiles: true,
|
||||
absolute: true,
|
||||
ignore: [
|
||||
'**/__tests__/fixtures/**',
|
||||
'src/**/public/**',
|
||||
'**/_*.{js,ts,tsx}',
|
||||
'**/*.test.*',
|
||||
'packages/**/target/**',
|
||||
],
|
||||
}
|
||||
)
|
||||
.forEach((file) => {
|
||||
process.argv.push(file);
|
||||
});
|
||||
}
|
||||
|
||||
if (runInBand) {
|
||||
require('mocha/bin/_mocha');
|
||||
} else {
|
||||
require('mocha/bin/mocha');
|
||||
}
|
||||
}
|
|
@ -1,25 +0,0 @@
|
|||
/*
|
||||
* Licensed to Elasticsearch B.V. under one or more contributor
|
||||
* license agreements. See the NOTICE file distributed with
|
||||
* this work for additional information regarding copyright
|
||||
* ownership. Elasticsearch B.V. licenses this file to you under
|
||||
* the Apache License, Version 2.0 (the "License"); you may
|
||||
* not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing,
|
||||
* software distributed under the License is distributed on an
|
||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
* KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
|
||||
// when the reporter is loaded by mocha in child process it might be before setup_node_env
|
||||
require('../../../../src/setup_node_env');
|
||||
|
||||
module.exports = require('./auto_junit_reporter').createAutoJUnitReporter({
|
||||
reportName: 'Server Mocha Tests',
|
||||
});
|
|
@ -1,21 +0,0 @@
|
|||
/*
|
||||
* Licensed to Elasticsearch B.V. under one or more contributor
|
||||
* license agreements. See the NOTICE file distributed with
|
||||
* this work for additional information regarding copyright
|
||||
* ownership. Elasticsearch B.V. licenses this file to you under
|
||||
* the Apache License, Version 2.0 (the "License"); you may
|
||||
* not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing,
|
||||
* software distributed under the License is distributed on an
|
||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
* KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
|
||||
require('../src/setup_node_env');
|
||||
require('@kbn/test').runMochaCli();
|
|
@ -17,6 +17,6 @@
|
|||
* under the License.
|
||||
*/
|
||||
|
||||
export { createAutoJUnitReporter, setupJUnitReportGeneration } from '@kbn/test';
|
||||
export { setupJUnitReportGeneration } from '@kbn/test';
|
||||
|
||||
export { generateNoticeFromSource } from './notice';
|
||||
|
|
|
@ -15,7 +15,6 @@ if [[ -z "$CODE_COVERAGE" ]] ; then
|
|||
|
||||
# Test
|
||||
./test/scripts/test/jest_integration.sh
|
||||
./test/scripts/test/mocha.sh
|
||||
./test/scripts/test/jest_unit.sh
|
||||
./test/scripts/test/api_integration.sh
|
||||
|
||||
|
|
|
@ -1,7 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
source src/dev/ci_setup/setup_env.sh
|
||||
|
||||
# TODO: will remove mocha in another PR
|
||||
# checks-reporter-with-killswitch "Mocha Tests" \
|
||||
# node scripts/mocha
|
|
@ -2,7 +2,7 @@
|
|||
"extends": "../tsconfig.base.json",
|
||||
"compilerOptions": {
|
||||
"incremental": false,
|
||||
"types": ["node", "mocha", "flot"]
|
||||
"types": ["node", "flot"]
|
||||
},
|
||||
"include": ["**/*", "../typings/elastic__node_crypto.d.ts", "typings/**/*", "../packages/kbn-test/types/ftr_globals/**/*"],
|
||||
"exclude": ["plugin_functional/plugins/**/*", "interpreter_functional/plugins/**/*"],
|
||||
|
|
|
@ -32,7 +32,6 @@ def test() {
|
|||
tasks([
|
||||
// These 2 tasks require isolation because of hard-coded, conflicting ports and such, so let's use Docker here
|
||||
kibanaPipeline.scriptTaskDocker('Jest Integration Tests', 'test/scripts/test/jest_integration.sh'),
|
||||
kibanaPipeline.scriptTaskDocker('Mocha Tests', 'test/scripts/test/mocha.sh'),
|
||||
|
||||
kibanaPipeline.scriptTask('Jest Unit Tests', 'test/scripts/test/jest_unit.sh'),
|
||||
kibanaPipeline.scriptTask('API Integration Tests', 'test/scripts/test/api_integration.sh'),
|
||||
|
|
|
@ -12,8 +12,7 @@
|
|||
"build": "../node_modules/.bin/gulp build",
|
||||
"testonly": "echo 'Deprecated, use `yarn test`'",
|
||||
"test": "../node_modules/.bin/gulp test",
|
||||
"test:jest": "node ../scripts/jest",
|
||||
"test:mocha": "node scripts/mocha"
|
||||
"test:jest": "node ../scripts/jest"
|
||||
},
|
||||
"kibana": {
|
||||
"build": {
|
||||
|
|
|
@ -39,7 +39,6 @@ module.exports = {
|
|||
'jquery',
|
||||
'lodash',
|
||||
'markdown-it',
|
||||
'mocha',
|
||||
'monaco-editor',
|
||||
'prop-types',
|
||||
'react-ace',
|
||||
|
|
|
@ -1,7 +0,0 @@
|
|||
/*
|
||||
* 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.
|
||||
*/
|
||||
|
||||
require('../../scripts/mocha');
|
|
@ -3,7 +3,7 @@
|
|||
"compilerOptions": {
|
||||
// overhead is too significant
|
||||
"incremental": false,
|
||||
"types": ["mocha", "node", "flot"]
|
||||
"types": ["node", "flot"]
|
||||
},
|
||||
"include": ["**/*", "../typings/**/*", "../../packages/kbn-test/types/ftr_globals/**/*"],
|
||||
"exclude": ["../typings/jest.d.ts"],
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue