Commit graph

108 commits

Author SHA1 Message Date
Spencer
90434765c0 [functionalTestRunner] replace intern (#10910)
* [functional_test_runner] replace functional testing tools with custom/pluggable solution

* [functional_test_runner] Convert unit tests to commonjs format

* [functional_test_runner] Fix dashboard test in wrong mode

* [functional_test_runner] Add dashboardLandingPage test subject

* [functional_test_runner] Get Visualize page object

* [functional_test_runner] Fix outdated references

* [functional_test_runner] Fix more outdated refs

* [functional_test_runner] Remove duplicate tests

* [functional_test_runner] Improve test readability

* [functional_test_runner] 😞 So many duplicate methods

* [functional_test_runner] Move mgmt `before` outside toplevel describe

* [functional_test_runner] Settings page obj missing methods

* [functional_test_runner] Add improvements from @gammon

* [functional_test_runner] Fix return statements in async funcs

* [functional_test_runner] Move before() to correct scope

* [functional_test_runner] Add after() hooks to remove index patterns

* [functional_test_runner] Attempt to fix vertical bar chart tests

* [functional_test_runner] Clean up

* [functional_test_runner] Reinstate unit tests

* [functional_test_runner] Set default loglevel back to info

* [functional_test_runner] Replace `context`s with `describe`s

* [functional_test_runner] Better error handling

* [functional_test_runner] Add in new Tile Map tests

* Incorporate changes from master

* [functional_test_runner] validate that every test file has a single top-level suite

* Update contributing doc with link to full doc

* [docs] Spelling and grammar fixes

* docs: writing and running functional tests

* [docs] Move plugin doc to plugin area

* [docs] Housekeeping. Doc in wrong place

* [docs] Remove dup doc file

* [grunt] Only run mocha_setup when running tests, not every grunt task
2017-04-11 17:01:06 -05:00
Spencer
e67790037a [esArchiver] combine elasticDump and ScenarioManager (#10359)
* As a part of bringing functional testing to plugins, esArchiver gives these plugins a way to capture and reload es indexes without needing to write a bunch of custom code. It works similarly to the elasticDump and ScenarioManager tools that it replaces.

Differences:
  - Streaming implementation allows for much larger archives
  - CLI for creating and using archives
  - Configurable archive location
  - Stores the data in gzipped files (better for source control, searching, large archives)
  - Automatically identifies and upgrades Kibana config documents

Methods:
  - `#load(name)`: import an archive
  - `#loadIfNeeded(name)`: import an archive, but skip the documents what belong to any existing index
  - `#unload(name)`: delete the indexes stored in an archive

CLI operations:
  - `./bin/es_archiver save <name> [index patterns...]`: save the mapping and documents in one or more indexes that match the wild-card patterns into an the `<name>` archive
  - `./bin/es_archiver load <name>`: load the mapping and documents from the `<name>` archive

* [functional_tests/common/nagivate] check for statusPage

* [es_archiver] move bins into new scripts dir

* [functional_tests/apps/context] use esArchiver

* [esArchiver] general improvements after showing to a few folks

 - remove auto-upgrading config doc logic (until we have better access to kibana version info)
 - export unload command
 - remove preemptive checks in favor of reacting to errors
 - use type "doc" vs "hit" for doc records (consistency)
 - wrote a bunch of pending tests to think though and plan

* [esArchiver] make log a stream that writes to itself

* [esArchiver] fill in stats and archive format tests

* [esArchiver] splitup action logic

* [esArchiver/cli] fix cli --help output and comment

* [esArchiver] remove type-based param coercion

* [esArchiver/log] use strings for log levels

* [esArchvier] remove unused var

* [esArchiver/indexDocRecordsStream] add tests

* [esArchive] fill in remaining tests

* [esArchiver] fix dem tests

* [eslint] remove unused vars

* [esArchiver/loadIfNeeded] fix call to load()

* [esArchiver] remove loadDumpData helpers
2017-03-27 15:29:14 -04:00
Spencer
d8d65526c6 [eslint] enable no undef (#10825)
* [codeshift] add proper ignore comments

* [codeshift] apply require-to-import transform

* [codeshift/fixup] remove duplicate imports

* [eslint] upgrade config for react "unused" support

* [codeshift] apply remove-unused-imports transform

* [codeshift] apply remove-unused-basic-requires transform

* [codeshift] apply remove-unused-function-arguments transform

* [lintroller] fix argument list spacing

* [codeshift] apply remove-unused-basic-bars transform

* [codeshift/fixup] fixup unused basic var removals

* manually apply remove-unused-assignments transform

* [codeshift] reapply remove-unused-imports transform

* [codeshift] reapply remove-unused-function-arguments transform

* [eslint] autofix param spacing

* manually fix remaining no-undef errors

* use more descriptive file ignore pattern

* add eslint-plugin-react peerDependency

* replace values that looked unused in tests

* remove // kibana-jscodeshift-no-babel comment

* remove import statements from code required by api tests

* Remove '// kibana-jscodeshift-ignore' comments

* address review feedback

* remove remnant of removed if condition
2017-03-22 07:08:23 -07:00
Spencer
db60725a02 [eslint] enable object-curly-spacing and no-global-assign (#9486)
* [eslint] update eslint config to 0.3.0

* [eslint] autofix

* [fixtures/hits] reformat to comply with max-len lint rule
2016-12-14 13:29:32 -07:00
Spencer
2f6654bcec [eslint] re-enable no-var and prefer-const (#9455)
* [eslint] enable no-var and autofix

* [eslint] enable prefer-const and autofix

* [eslint] fix autofix-incompatible no-var and prefer-const violations
2016-12-13 10:44:27 -07:00
Jim Unger
6e819c11b8 Remove legacy pipelines code (#9397)
* Removes legacy pipelines code from kibana core_plugin

* removes pipelines tests
2016-12-08 16:05:18 -06:00
Matthew Bargar
b7fd17b492 Remove other unused Add Data code 2016-09-29 15:14:19 -04:00
Matthew Bargar
b15625b9d8 Remove Upload Data API 2016-09-29 14:55:48 -04:00
Matthew Bargar
1af6b76bd4 Add field_capabilities API
This adds a simple API for getting the searchable/aggregatable status of
a list of fields in a given index, list of indices, or index pattern. In
the future this will probably evolve into a full blown fields info API
that we can use when removing the index pattern mapping cache. For now
though it's built to provide the minimum info needed to fix
https://github.com/elastic/kibana/issues/6769

Usage:

The API exposes a single GET endpoint.

```
GET /api/kibana/{indices}/field_capabilities
```

`indices` can be a single index, a comma delimited list, or a wildcard
pattern

Example response:

```
{
  "fields": {
    "imsearchable": {
      "searchable": true,
      "aggregatable": false
    },
    "imaggregatable": {
      "searchable": true,
      "aggregatable": true
    },
  }
}
```
2016-09-23 10:30:44 -04:00
Jim Unger
a35aac2c5d Removed pipelines from ingest endpoint, and import csv wizard 2016-08-31 12:36:55 -05:00
Matthew Bargar
6c8ec66b3a Add a new GET script languages API endpoint
To provide additional language options for scripted fields, Kibana needs
to know what languages are available for inline scripting in
Elasticsearch. This new Kibana API grabs up to date information from
Elasticsearch and provides it in an easy to digest format for the UI.

The response body from the API is a simple JSON array with a list of
languages that are enabled for inline scripting. The API also filters
out languages that don't make sense in scripted fields, like 'mustache'.

An example request might look like this:

`GET /api/kibana/scripts/languages`

200 OK
`['expression', 'painless']`
2016-08-29 11:26:27 -04:00
Jonathan Budzenski
b3c6a13bad
[api tests] update pipeline tests to grab id from object keys instead of array index 2016-08-09 11:36:51 -05:00
Matthew Bargar
24a034e9f9 [API] Add metafields from uiSettings to index patterns created by ingest API 2016-06-01 18:14:51 -04:00
Matthew Bargar
3143c069ff Added API test so we don't forget that the ID format is a part of the public contract 2016-05-25 18:36:37 -04:00
Matthew Bargar
475913d15a Change delimiter query param to csv_delimiter so better namespace it when other data types are supported in the future 2016-05-11 15:23:48 -04:00
Matthew Bargar
08427eeba7 Rename data dir to fixtures 2016-05-11 15:05:11 -04:00
Matthew Bargar
05b198a819 Merge branch 'feature/ingest' into ingest/bulkAPI 2016-05-10 18:27:51 -04:00
Matthew Bargar
bc65d9509d Change _bulk to _data 2016-05-10 17:02:31 -04:00
Matthew Bargar
81ea488170 Better date field detection without flaky pipeline introspection 2016-05-04 16:21:28 -04:00
Matthew Bargar
ab5e444ed4 Fix lint issues 2016-04-29 16:47:29 -04:00
Matthew Bargar
bfba35f704 [API] Accept both multipart/form-data and raw payloads
* The _bulk api will now accept raw CSV data as the main request payload
* Submitting the CSV data as a form-data key is still an option
* All other parameters have moved from form-data to the query string

Also: Improved delimiter test so it actually checks the keys of created
documents to ensure the delimiter is working.
2016-04-29 16:47:29 -04:00
Matthew Bargar
89988b8319 Update test for new lower bulk size 2016-04-29 16:47:29 -04:00
Matthew Bargar
6ceca8b1ba [API] Functional tests for _bulk API 2016-04-29 16:47:29 -04:00
Jim Unger
b2f30f931a Merge branch 'feature/ingest' into add-data-disable-processors 2016-04-26 15:13:49 -05:00
Jim Unger
a9048e7452 [add data] hides disabled processors 2016-04-26 13:54:54 -05:00
Jim Unger
612725117d [add data] adds the uppercase processor 2016-04-13 09:56:55 -05:00
Jim Unger
6904664236 [add data] adds the trim processor 2016-04-13 09:02:09 -05:00
Jim Unger
07664a85a8 [add data] adds the split processor 2016-04-12 13:42:21 -05:00
Jim Unger
33dd6d660e [add data] adds rename processor 2016-04-12 13:18:02 -05:00
Jim Unger
f62ebc4d62 [add data] adds the remove processor 2016-04-12 12:03:15 -05:00
Jim Unger
d42ac6ea12 [add data] adds the lowercase processor 2016-04-12 11:24:49 -05:00
Jim Unger
335c82a022 [add data] adds the join processor 2016-04-11 16:53:47 -05:00
Jim Unger
093ccedc37 [add data] adds grok processor 2016-04-11 15:42:57 -05:00
Jim Unger
96cbe8997b [add data] adds the geoip processor 2016-04-11 13:54:06 -05:00
Jim Unger
6bd9dba66a Merge branch 'feature/ingest' into add-data-processors-date 2016-04-11 12:19:47 -05:00
Jim Unger
70be789208 [add data] fixed test comment 2016-04-08 14:17:14 -05:00
Jim Unger
14799bf182 [add data] adds the date processor 2016-04-08 13:27:23 -05:00
Jim Unger
61dd02ee5d [add data] added auto type and target field to convert processor 2016-04-08 10:14:01 -05:00
Jim Unger
3fe7dd9adc Merge branch 'feature/ingest' into add-data-processors-convert 2016-04-08 09:28:48 -05:00
Jim Unger
7de50bf2bd [add data] Finished adding the append processor 2016-04-07 12:59:43 -05:00
Jim Unger
930a44dfa9 [add data] adds convert processor 2016-04-07 12:56:00 -05:00
Jim Unger
4317045ff4 [add data] removed dirtyProcessor logic. 2016-04-06 16:43:20 -05:00
Jim Unger
ea71928f72 [add data] added error-flow tests to the _simulate suite 2016-04-06 16:12:20 -05:00
Jim Unger
c63a5a2c76 [add data] Attempts to deal with unhandled errors in the ingest API 2016-04-05 11:11:51 -05:00
Jim Unger
7278cb31aa [ingest] small tweek 2016-03-28 14:46:42 -05:00
Matthew Bargar
bbd718708c Merge branch 'master' into feature/ingest 2016-03-18 16:10:43 -04:00
Jim Unger
91be043bc3 [ingest client] fixes invalid-set-processor simulate test 2016-03-18 08:21:10 -05:00
Matthew Bargar
017a6117f7 Update ingest API for ES 5.0 mapping changes 2016-03-16 18:01:10 -04:00
Matthew Bargar
2c32d9fc3f Update ingest POST endpoint to accept the new processor schema 2016-03-16 16:38:20 -04:00
Matthew Bargar
98f9f53008 Merge branch 'master' into feature/ingest 2016-03-15 19:21:16 -04:00