kibana/scripts
Spencer f24a725144
[mocha] remove grunt-simple-mocha (#19079)
* [mocha] run tests with mocha script, remove grunt-simple-mocha

* [ci] force colored output

* [ci] disable color when reading the yarn bin

* [dev/build/exec] support tooling log having its own chalk

* [dev/mocha] avoid changing the cwd of the process

* [dev/mocha] only match files, speed up negative matches

* [cli/serve/test] strip ansi control characters from logs

* [ci] disable color in all `yarn bin` invocations

* [dev/mocha] cleanup old runInBand check

* [dev/mocha] enable gloabl leak checks
2018-05-16 10:43:55 -07:00
..
backport.js Add Backport to toolchain (#14525) 2017-10-24 16:38:18 -04:00
build.js Migrate x-pack-kibana source to kibana 2018-04-24 13:48:10 -07:00
docs.js create babel-preset and babel-register modules (#13973) 2017-09-19 17:44:47 -07:00
es.js [kbn-es] Use basic license as default (#18577) 2018-04-25 14:00:24 -07:00
es_archiver.js create babel-preset and babel-register modules (#13973) 2017-09-19 17:44:47 -07:00
eslint.js [eslint] add eslint dev script (#14889) 2017-11-14 10:11:59 -07:00
functional_test_runner.js create babel-preset and babel-register modules (#13973) 2017-09-19 17:44:47 -07:00
functional_tests.js Functional test setup with kbn-test package (#18568) 2018-05-09 18:23:49 -05:00
functional_tests_server.js Functional test setup with kbn-test package (#18568) 2018-05-09 18:23:49 -05:00
generate_plugin.js [kbn-plugin-generator] add plugin generator to the repo (#16655) 2018-02-12 12:23:23 -07:00
jest.js Introduce Jest integration tests. (#16735) 2018-02-19 17:02:01 +01:00
jest_integration.js Introduce Jest integration tests. (#16735) 2018-02-19 17:02:01 +01:00
kbn.js [kbn-pm] rename from kbn-build (#16739) 2018-02-14 10:57:13 -07:00
kibana.js Create separate startup scripts for development and production (#13806) 2017-11-22 12:49:37 -06:00
kibana_keystore.js Snake case scripts/kibana-keystore.js and scripts/kibana-plugin.js (#15331) 2018-02-02 09:54:02 -06:00
kibana_plugin.js Snake case scripts/kibana-keystore.js and scripts/kibana-plugin.js (#15331) 2018-02-02 09:54:02 -06:00
makelogs.js Convert makelogs and mocha npm scripts (#11665) 2017-05-09 10:53:10 -07:00
mocha.js [mocha] remove grunt-simple-mocha (#19079) 2018-05-16 10:43:55 -07:00
notice.js Add/generate/verify NOTICE.txt file (#17504) 2018-04-04 09:12:44 -07:00
precommit_hook.js [precommit hook] add dev script (#14890) 2017-11-20 14:22:24 -07:00
README.md Functional test setup with kbn-test package (#18568) 2018-05-09 18:23:49 -05:00

Kibana Dev Scripts

This directory contains scripts useful for interacting with Kibana tools in development. Use the node executable and --help flag to learn about how they work:

node scripts/{{script name}} --help

For Developers

This directory is excluded from the build and tools within it should help users discover their capabilities. Each script in this directory must:

  • require src/babel-register to bootstrap babel
  • call out to source code in the src or packages directories
  • react to the --help flag
  • run everywhere OR check and fail fast when a required OS or toolchain is not available

Functional Test Scripts

node scripts/functional_tests [--config test/functional/config.js --config test/api_integration/config.js]

Runs all the functional tests: selenium tests and api integration tests. List configs with multiple --config arguments. Uses the @kbn/test library to run Elasticsearch and Kibana servers and tests against those servers, for multiple server+test setups. In particular, calls out to runTests(). Can be run on a single config.

node scripts/functional_tests_server [--config test/functional/config.js]

Starts just the Elasticsearch and Kibana servers given a single config, i.e. via --config test/functional/config.js or --config test/api_integration/config. Allows the user to start just the servers with this script, and keep them running while running tests against these servers. The idea is that the same config file configures both Elasticsearch and Kibana servers. Uses the startServers() method from @kbn/test library.

Example. Start servers and run tests, separately, but using the same config:

# Just the servers
node scripts/functional_tests_server --config path/to/config

In another terminal:

# Just the tests--against the running servers
node scripts/functional_test_runner --config path/to/config

For details on how the internal methods work, read this readme.