Commit graph

3815 commits

Author SHA1 Message Date
Nicolas Chaulet 3b1e8b03f1
[Fleet] Install final pipeline (#100973) 2021-06-03 12:27:29 -04:00
Candace Park 0312839e34
[Security Solution][Endpoint][Host Isolation] Unisolate host minor refactors (#100889) 2021-06-03 12:27:06 -04:00
Devon Thomson a0c20ac7aa
[Dashboard] Fix Copy To Permission & Unskip RBAC tests (#100616)
* slightly better typing for dashboard permissions. Fixed typo, unskipped functional tests
2021-06-03 11:58:25 -04:00
Stratoula Kalafateli a9a9013120
[Pie] New implementation of the vislib pie chart with es-charts (#83929)
* es lint fix

* Add formatter on the buckets labels

* Config the new plugin, toggle tooltip

* Aff filtering on slice click

* minor fixes

* fix eslint error

* use legacy palette for now

* Add color picker to legend colors

* Fix ts error

* Add legend actions

* Fix bug on Color Picker and remove local state as it is unecessary

* Fix some bugs on colorPicker

* Add setting for the user to select between the legacy palette or the eui ones

* small enhancements, treat empty labels with (empty)

* Fix color picker bugs with multiple layers

* fixes on internationalization

* Create migration script for pie chart and legacy palette

* Add unit tests (wip) and a small refactoring

* Add unit tests and move some things to utils, useMemo and useCallback where it should

* Add jest config file

* Fix jest test

* fix api integration failure

* Fix to_ast_esaggs for new pie plugin

* Close legendColorPicker popover when user clicks outside

* Fix warning

* Remove getter/setters and refactor

* Remove kibanaUtils from pie plugin as it is not needed

* Add new values to the migration script

* Fix bug on not changing color for expty string

* remove from migration script as they don't need it

* Fix editor settings for old and new implementation

* fix uistate type

* Disable split chart for the new plugin for now

* Remove temp folder

* Move translations to the pie plugin

* Fix CI failures

* Add unit test for the editor config

* Types cleanup

* Fix types vol2

* Minor improvements

* Display data on the inspector

* Cleanup translations

* Add telemetry for new editor pie options

* Fix missing translation

* Use Eui component to detect click outside the color picker popover

* Retrieve color picker from editor and syncColors on dashboard

* Lazy load palette service

* Add the new plugin to ts references, fix tests, refactor

* Fix ci failure

* Move charts library switch to vislib plugin

* Remove cyclic dependencies

* Modify license headers

* Move charts library switch to visualizations plugin

* Fix i18n on the switch moved to visualizations plugin

* Update license

* Fix tests

* Fix bugs created by new charts version

* Fix the i18n switch problem

* Update the migration script

* Identify if colorIsOverwritten or not

* Small multiples, missing the click event

* Fixes the UX for small multiples part1

* Distinct colors per slice implementation

* Fix ts references problem

* Fix some small multiples bugs

* Add unit tests

* Fix ts ref problem

* Fix TS problems caused by es-charts new version

* Update the sample pie visualizations with the new eui palette

* Allows filtering by the small multiples value

* Apply sortPredicate on partition layers

* Fix vilib test

* Enable functional tests for new plugin

* Fix some functional tests

* Minor fix

* Fix functional tests

* Fix dashboard tests

* Fix all dashboard tests

* Apply some improvements

* Explicit params instead of visConfig Json

* Fix i18n failure

* Add top level setting

* Minor fix

* Fix jest tests

* Address PR comments

* Fix i18n error

* fix functional test

* Add an icon tip on the distinct colors per slice switch

* Fix some of the PR comments

* Address more PR comments

* Small fix

* Functional test

* address some PR comments

* Add padding to the pie container

* Add a max width to the container

* Improve dashboard functional test

* Move the labels expression function to the pie plugin

* Fix i18n

* Fix functional test

* Apply PR comments

* Do not forget to also add the migration to them embeddable too :D

* Fix distinct colors for IP range layer

* Remove console errors

* Fix small mulitples colors with multiple layers

* Fix lint problem

* Fix problems created from merging with master

* Address PR comments

* Change the config in order the pie chart to not appear so huge on the editor

* Address PR comments

* Change the max percentage digits to 4

* Change the max size to 1000

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-06-03 18:17:14 +03:00
spalger f5df40a5a1 skip flaky suite (#99581) 2021-06-03 06:33:27 -07:00
Shahzad 2ea4d5713c
[Uptime] Move uptime to new solution nav (#100905)
* Expose options to customize the route matching

* Add more comments

* move uptime to new solution nav

* push

* update test

* add an extra breadcrumb

Co-authored-by: Felix Stürmer <stuermer@weltenwort.de>
2021-06-03 15:19:35 +02:00
spalger 98527ad232 skip suite failing es promotion (#101219) 2021-06-02 14:14:58 -07:00
Tre dc5511f73b
[QA] Bind the retry to fixup error in it repo tests (#100948)
Verfiied via: https://internal-ci.elastic.co/view/All/job/elastic+integration-test+master/487/
2021-06-02 12:28:59 -06:00
Mike Côté e607b58590
Fix alerting health API to consider rules in all spaces (#100879)
* Initial commit

* Expand tests

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-06-02 13:08:09 -04:00
Bhavya RM 2dfda12af1
Unskip advanced settings a11y test (#100558) 2021-06-02 12:03:19 -04:00
Robert Oskamp f4f8ea73f9
[ML] Functional tests - reenable categorization tests (#101137)
This PR re-enables the categorization tests that have been temporarily skipped.
2021-06-02 16:32:53 +02:00
Joe Reuter 8cb3dbc4ab
[Lens] Time shift metrics (#98781) 2021-06-02 15:58:47 +02:00
CJ Cenizal ba4e0d259b
Migrate CCR to new ES JS client. (#100131)
* Update SectionError component to render error root causes correctly.
* Fix 404 error rendering.
* Add test for follower index update API route.
2021-06-01 16:26:01 -07:00
Corey Robertson b62848ce8a
[Canvas] Switch Canvas to use React Router (#100579)
* Switch Canvas to use React Router

* Fix typescript errors

* Remove @scant/router from package.json

* Fix tests

* Fix functional test

* Fix functional tests

* Fix bad merge in package.json

* Cleanup from code review comments

* Fix double basepath append

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-06-01 17:35:56 -04:00
Tyler Smalley 0f9debeba7
[FTR] Use importExport for saved_object/basic archive (#100244)
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
2021-06-01 11:50:49 -07:00
Thom Heymann 27f790c8f2
Create API keys with metadata (#100682) 2021-06-01 19:55:11 +03:00
Robert Oskamp 77f0a2a7ad
[ML] Functional tests - disable categorization tests (#101057)
This PR temporarily disables categorization tests.
2021-06-01 18:12:31 +02:00
Greg Thompson 38fd8a268a
Upgrade EUI to v33.0.0 (#99382)
* eui to 33.0.0

* resize observer type inclusion - revisit

* src snapshot updates

* x-pack snapshot updates

* table sort test updates

* code block language sh -> bash

* datagrid datetime sort inversion

* types

* kbn-crypto

* refractor yarn resolution

* refractor yarn resolution

* update cypress tests

* url state test

* trial

* Revert "trial"

This reverts commit adc3538145.

* trial anomaly timeout

* Revert "trial anomaly timeout"

This reverts commit 9a11711ba8.

* kbn-telemetry-tools

* Change a useMemo to useCallback so the code executes when intended

* Removed no-longer-used import

* exitOrFail already retries for longer than tryForTime

* Wait for loading indicator to disappear

* Intentionally adding `.only`

* Revert .only

* Increase wait time for the ML chart to load

* Remove unused var

* overflow

* chartWidth

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Alejandro Fernández Haro <alejandro.haro@elastic.co>
Co-authored-by: Chandler Prall <chandler.prall@gmail.com>
2021-06-01 10:53:07 -05:00
Jason Rhodes 8ed2add1a2
Re-enable _mb suffixed stack monitoring func tests (#98354)
* Reenabled _mb suffixed stack monitoring func tests

These tests were disabled temporarily in #98238 because of intermittent failures in master.

* use test_user instead of basic_monitoring_user

* remove security service

* remove logout and cleanup

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: neptunian <sandra.gonzales@elastic.co>
2021-06-01 10:58:39 -04:00
Tiago Costa 19b8aa798c
skip flaky suite (#90565) 2021-06-01 12:54:15 +01:00
Tiago Costa 25f569ae3d
skip flaky suite (#64473) 2021-06-01 12:49:51 +01:00
Tiago Costa 622bf0bf5a
skip flaky suite (#100570) 2021-05-31 16:23:58 +01:00
Joe Reuter 79fa4f405b
[Lens][Dashboard] Share session between lens and dashboard (#100214) 2021-05-31 11:14:31 +02:00
Robert Oskamp 3ef24aa56c
[ML] Functional tests - reenable DFA feature importance suite (#100850)
This PR re-enables the data frame analytics feature importance test suite.
2021-05-31 09:29:37 +02:00
Davis Plumlee 418a3d312c
[Security Solution][Detections] Update rule integration tests (#98512) 2021-05-28 21:40:57 -04:00
James Gowdy e93c18fea7
[ML] Fixing management app race condition (#100785)
* [ML] Fixing management app race condition

* updating test id

* translation id

* adding link to license page

* fixing tests

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-28 21:23:10 +01:00
Bhavya RM 4989ec266b
updating the saved objects test to include more saved object types (#100828) 2021-05-28 13:04:59 -04:00
Jonathan Buttner 692806aed8
Fixing ES archive mapping failure (#100835)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-28 12:21:34 -04:00
David Sánchez cec62cb706
[Security Solution][Endpoint] Add event filters summary card to the fleet endpoint tab (#100668)
* Shows event filters card on fleet page

* Uses aggs instead of while loop to retrieve summary data

* Add request and response types in the lists package

* Fixes old import

* Removes old i18n keys

* Removes more old i18n keys

* Use consts for exception lists url and endpoint event filter list id

* Uses event filters service to retrieve summary data

* Fixes addressed pr comments such as changing the route without underscore, adding aggs type, validating response, and more

* Uses useMemo instead of useState to memoize object

* Add new e2e test for summart endpoint

* Handle api errors on event filters and trusted apps summary api calls

* Add api error message to the toast

* Fix wrong i18n key

* Change span tag by react fragment

* Uses styled components instead of modify compontent style directly and small improvements on test -> ts

* Adds curls script for summary route

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-28 18:07:54 +02:00
Marco Liberati 51616e1b8d
[Lens] Adds dynamic table cell coloring (#95217)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Greg Thompson <thompson.glowe@gmail.com>
Co-authored-by: Michael Marcialis <michael@marcial.is>
2021-05-28 15:24:28 +02:00
Spencer 9538788611
[ftr] migrate "MenuToggle" service to FtrService class (#100608)
Co-authored-by: spalger <spalger@users.noreply.github.com>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-28 07:10:32 +02:00
Yuliia Naumenko 134a3def03
[Actions] Converted rejectUnauthorized config usages to verificationMode. (#100179)
* [Actions] Converted `rejectUnauthorized` config usages to `verificationMode`.

* added new verificationMode config options for tls, proxy tls and custom hosts

* added unit tests

* added unit tests

* added kibana docker

* Apply suggestions from code review

Co-authored-by: gchaps <33642766+gchaps@users.noreply.github.com>

* Update alert-action-settings.asciidoc

* Apply suggestions from code review

Co-authored-by: Joe Portner <5295965+jportner@users.noreply.github.com>

* removed legacyRegectUnauthorized logic from getNodeTLSOptions

* added deprecations

* fixed doc links

* fixed docs

* Update x-pack/plugins/actions/server/builtin_action_types/lib/send_email.ts

Co-authored-by: Joe Portner <5295965+jportner@users.noreply.github.com>

* [DOCS] Fixes build error

* fixed deprecations to set custom message

* fixed doc

* changed to not throw exception on non existing verification mode

* added tests

* fixed tests

* fixed tests

* added integration tests for legacy rejectUnauthorized fale

* fixed tests

Co-authored-by: gchaps <33642766+gchaps@users.noreply.github.com>
Co-authored-by: Joe Portner <5295965+jportner@users.noreply.github.com>
Co-authored-by: lcawl <lcawley@elastic.co>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-27 14:20:57 -07:00
spalger a6bbf1b219 skip suite failing es promotion (#100697) 2021-05-27 14:10:49 -07:00
ymao1 71379b755a
[Alerting] Split alerting feature privilege between rules and alerts and handle subfeature privilege specification (#100127)
* WIP - creating alerting authorization client factory and exposing authorization client on plugin start contract

* Updating alerting feature privilege builder to handle different alerting types

* Passing in alerting authorization type to AlertingActions class string builder

* Passing in authorization type in each function call

* Passing in exempt consumer ids. Adding authorization type to audit logger

* Changing alertType to ruleType

* Changing alertType to ruleType

* Updating unit tests

* Updating unit tests

* Passing field names into authorization query builder. Adding kql/es dsl option

* Converting to es query if requested

* Fixing functional tests

* Removing ability to specify feature privilege name in constructor

* Fixing some types and tests

* Consolidating alerting authorization kuery filter options

* Cleanup and tests

* Cleanup and tests

* Initial commit with changes needed for subfeature privilege

* Throwing error when AlertingAuthorizationClientFactory is not defined

* Renaming authorizationType to entity

* Renaming AlertsAuthorization to AlertingAuthorization

* Fixing unit tests

* Changing schema of alerting feature privilege

* Changing schema of alerting feature privilege

* Updating feature privilege iterator

* Updating feature privilege builder

* Fixing types check

* Updating privilege string terminology

* Updating privilege string terminology

* Wip

* Fixing unit tests

* Unit tests

* Updating README and removing stack subfeature privilege changes

* Fixing README

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-27 14:59:02 -04:00
Jonathan Budzenski f0e11bcd1b
Automated package testing (#88900)
Co-authored-by: Tyler Smalley <tylersmalley@me.com>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-27 13:37:43 -05:00
Anton Dosov 806566c62e
[Index Patterns] Migrate tests to the new es client (#100760) 2021-05-27 15:47:30 +02:00
Patrick Mueller 11b3ab167d
[alerting] add ignore_above to alerts params mappings to handle immense params (#100726)
resolves https://github.com/elastic/kibana/issues/100607

This fixes a problem when very large parameters (over 32K bytes) are saved with
an alert.  Before this fix, an error from elasticsearch would be thrown with
the following message, and a 400 returned from create (and presumably update).

    Document contains at least one immense term in field=\"alert.params\"
    (whose UTF8 encoding is longer than the max length 32766), all of which
    were skipped.

After the fix, alerts with immense params can be saved and executed.

Note that the immense params will not be searchable, since they won't be indexed,
but that seems both unavoidable, and not a severe issue.
2021-05-27 09:17:12 -04:00
Alejandro Fernández Gómez 83e5b6c689
[Fleet] Remove beats management plugin (#99789) 2021-05-27 11:30:15 +02:00
Pete Harverson f77ff2d396
[ML] Adds functional tests for anomaly detection job custom URLs (#100455)
* [ML] Adds functional tests for anomaly detection job custom URLs

* [ML] Remove debug test tag from custom URL tests

* [ML] Update custom URL editor Jest snapshots

* [ML] Clean up in embeddables tests to fix dashboard test

* [ML] Delete test dashboard after test suites complete

* [ML] Edits to custom URL tests following review

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-26 17:48:03 +01:00
Nathan Reese e49db7127d
[Maps] filter dashboard by map extent (#99860)
* [Maps] filter dashboard by map extent

* clean up

* remove warning from filter pill

* tslint

* API doc updates, i18n fixes, tslint

* only show context menu option in edit mode

* add functional test

* review feedback

* do not use search session when filtering by map bounds

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-26 08:51:39 -06:00
Sandra Gonzales ce6f923bb4
fix anomaly functional test (#100504)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-26 10:25:39 -04:00
Larry Gregory 5d5cc55b3a
Fix spaces test flakyness (#100605) 2021-05-26 06:47:28 -04:00
Nathan L Smith e61c6660f7
Open/Closed filter for observability alerts page (#99217) 2021-05-25 12:40:14 -05:00
Spencer 111e15a054
[ftr] implement FtrService classes and migrate common services (#99546)
Co-authored-by: spalger <spalger@users.noreply.github.com>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-25 09:25:09 -07:00
David Sánchez ca324c63be
Removes event filters feature flag and exposes this feature by default (#100389)
* Removes event filters feature flag and expose this feature by default

* Fixes manifest unit test

* Fixes functional test adding event filter list case

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-25 15:19:42 +02:00
Sandra Gonzales 60b5c842cd
[Metrics UI] use EuiTooltip to control tooltip component and simplify ConditionalTooltip (#99224)
* use EuiTooltip to control tooltip component

* fix style

* update unit tests

* add functional waffle map tooltip tests

* remove reload() from useEffect

* fix type

* update unit test
2021-05-25 08:51:24 -04:00
Frank Hassanabad aa2f5b535d
[Security Solution] Utilizes constants package and deletes duplicate code (#100513)
## Summary

Utilizes constants package and deletes duplicate code

* Renames the `securitysolution-constants` to be `securitysolution-list-constants` to be specific
* Deletes duplicated code found during cleanup
* Moves more tests into the packages found along the way with the duplicated code
* Moves `parseScheduleDates` from `@kbn/securitysolution-io-ts-types` to `@kbn/securitysolution-io-ts-utils`

### Checklist

- [x] [Unit or functional tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html) were updated or added to match the most common scenarios
2021-05-24 18:38:14 -06:00
Mikhail Shustov 95e8eed7d1
security solution and lists to TS incremental builds (#100447)
* lists to ts incremental builds

* security_solution to ts incremental

* import ResizeObserver explicitly as it is not declared in dom types
2021-05-24 16:34:29 +02:00
ymao1 496999fbfc
[Alerting] Passing additional rule fields to rule executor (#99819)
* Passing additional rule fields to rule executor

* Fixing types check

* Api docs

* Adding enabled and actions

* Api docs

* Encapsulating rule information into RuleConfig type

* Functional tests

* Functional tests

* Adding producer, ruleTypeId and ruleTypeName

* Api docs

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-24 10:25:52 -04:00
Brian Seeders b1a95e4296 skip flaky suite (#100445) 2021-05-22 18:06:57 -04:00
Frank Hassanabad 9bf488e826
[Security Solutions] Re-arranges and adds more packages to remove copied code (#100310)
## Summary

* Creates a `securitysolution-list-utils` packaged and moves the first set of utilities into there
* Fixes a slight bug with `kbn-securitysolution-io-ts-list-types` where the wrong name was used
* Moves _all_ of the lists schemas and types into the package `kbn-securitysolution-io-ts-list-types`
* Removes copied code found in a few places

## Tech debt
* Some spots I have to use an `any` in the package as Kibana kbn packages don't have the types I need
* Some spots I copy constants until we can straighten out those pieces.
* I keep copied mock files until we figure out how to share mocks from these packages without adding weight or we create dedicated mock packages for all of this. 


### Checklist

- [x] [Unit or functional tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html) were updated or added to match the most common scenarios
2021-05-19 15:59:52 -06:00
Kevin Logan 00479968a1
[Security Solution] Add linux malware config options and migration (#100166) 2021-05-19 17:37:43 -04:00
liza-mae c28b5496a6
Upgrade functional test fixes (#100306)
* Upgrade functional test fixes

* Fix lint issues
2021-05-19 13:08:41 -06:00
spalger 4b0c01a732 skip flaky suite (#99581) 2021-05-19 09:34:14 -07:00
Kevin Logan 9da1a707d7
[Security Solution] Add supported field to ransomware (#100135) 2021-05-19 11:43:18 -04:00
Tiago Costa 8f1bf66a7b
skip flaky suite (#100296) 2021-05-19 13:13:07 +01:00
ymao1 0f0cee2510
[Alerting] Refactor alerts authorization client (#99078)
* WIP - creating alerting authorization client factory and exposing authorization client on plugin start contract

* Updating alerting feature privilege builder to handle different alerting types

* Passing in alerting authorization type to AlertingActions class string builder

* Passing in authorization type in each function call

* Passing in exempt consumer ids. Adding authorization type to audit logger

* Changing alertType to ruleType

* Changing alertType to ruleType

* Updating unit tests

* Updating unit tests

* Passing field names into authorization query builder. Adding kql/es dsl option

* Converting to es query if requested

* Fixing functional tests

* Removing ability to specify feature privilege name in constructor

* Fixing some types and tests

* Consolidating alerting authorization kuery filter options

* Cleanup and tests

* Cleanup and tests

* Throwing error when AlertingAuthorizationClientFactory is not defined

* Renaming authorizationType to entity

* Renaming AlertsAuthorization to AlertingAuthorization

* Fixing unit tests

* Updating privilege string terminology

* Updating privilege string terminology

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-18 18:32:43 -04:00
Frank Hassanabad 0f9766591f
[Security Solution] Re-adds a test that was skipped (#100273)
## Summary

Re-adds a test that was skipped. If it goes bonkers again, I will add more debugging information to it. I will keep an eye on the operations channel to see when/if this fails again. Originally this looked to be timeouts waiting, so I increased the global timeout to be 20 seconds instead of the original 10 seconds.

Resolves:
https://github.com/elastic/kibana/issues/89389

### Checklist

- [x] [Unit or functional tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html) were updated or added to match the most common scenarios
2021-05-18 13:03:49 -05:00
Kevin Logan 79c94d33fb
[Security Solution] Fix policy details test (#100260) 2021-05-18 13:14:31 -04:00
Thom Heymann 574b4559e7
Simplify deleting spaces (#99960)
* Simplify deleting spaces

* Fixed i18n

* Fix functional tests

* Update x-pack/plugins/spaces/public/management/spaces_management_app.tsx

Co-authored-by: Larry Gregory <lgregorydev@gmail.com>

* Fix snapshots

Co-authored-by: Larry Gregory <lgregorydev@gmail.com>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-18 11:37:18 +01:00
Frank Hassanabad e15b887e43
[Security Solutions] Replaces most deprecated io-ts alerting and list types (#100234)
## Summary

Replaces most of the deprecated io-ts alerting and list types within securitysolution as part of Phase 3 of 4 phases outlined in earlier PR's such as https://github.com/elastic/kibana/pull/99260

### Checklist

- [x] [Unit or functional tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html) were updated or added to match the most common scenarios
2021-05-17 23:28:06 -06:00
Dominique Clarke 6d4cca29a7
[Uptime] [Synthetics Integration] Add functional tests for Synthetics Integration (#100161)
* add functional tests for synthetics fleet package
2021-05-17 16:44:30 -04:00
Brian Seeders f1a2e6f251 skip flaky suite (#100236) 2021-05-17 15:53:20 -04:00
Tiago Costa cbab391bbe
skip failing es promotion suite (#99915) 2021-05-17 18:48:41 +01:00
Spencer 808b44f2c1
[kbn/test] move types/ftr into src (#99555)
* [kbn/test] move types/ftr into src

* Apply eslint updates

* fix import of Lifecycle type

Co-authored-by: spalger <spalger@users.noreply.github.com>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-17 09:51:53 -07:00
Tiago Costa d079dae56d
skip failing es promotion suite (#99915) 2021-05-17 16:21:46 +01:00
Tiago Costa 839fc7b257
skip failing es promotion suite (#99915) 2021-05-17 16:19:56 +01:00
Dzmitry Lemechko e63c319032
[QA] fix dashboard lens by value test (#100196)
* [functional test] remove redundant navigation, wait for lens to be loaded

* fix navigation to new viz

* update test title

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-17 17:18:20 +02:00
Tiago Costa 8d85d72fef
skip flaky suite (#100012) 2021-05-17 16:12:08 +01:00
Dzmitry Lemechko ca2930c719
[status_page test] use navigateToApp (#100146) 2021-05-15 00:17:10 +02:00
Joe Portner b2d36b863b
Sharing saved objects phase 3 (#94383) 2021-05-14 14:46:17 -04:00
Dominique Clarke 25cad22b3d
[Uptime] Fix overview flaky tests (#99781)
* add retry logic and add describe.only to prepare for flaky test runner

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-14 14:33:46 -04:00
John Schulz 0364e8f5aa
[Fleet] Fix error when searching for keys whose names have spaces (#100056)
## Summary
fixes #99895

Can reproduce #99895 with something like
```shell
curl 'http://localhost:5601/api/fleet/enrollment-api-keys' \
  -H 'content-type: application/json' \
  -H 'kbn-version: 8.0.0' \
  -u elastic:changeme \
  --data-raw '{"name":"with spaces","policy_id":"d6a93200-b1bd-11eb-90ac-052b474d74cd"}'
```

Kibana logs this stack trace

```
server    log   [10:57:07.863] [error][fleet][plugins] KQLSyntaxError: Expected AND, OR, end of input but "\" found.
policy_id:"d6a93200-b1bd-11eb-90ac-052b474d74cd" AND name:with\ spaces*
--------------------------------------------------------------^
    at Object.fromKueryExpression (/Users/jfsiii/work/kibana/src/plugins/data/common/es_query/kuery/ast/ast.ts:52:13)
    at listEnrollmentApiKeys (/Users/jfsiii/work/kibana/x-pack/plugins/fleet/server/services/api_keys/enrollment_api_key.ts:37:69)
    at Object.generateEnrollmentAPIKey (/Users/jfsiii/work/kibana/x-pack/plugins/fleet/server/services/api_keys/enrollment_api_key.ts:160:31)
    at processTicksAndRejections (internal/process/task_queues.js:93:5)
    at postEnrollmentApiKeyHandler (/Users/jfsiii/work/kibana/x-pack/plugins/fleet/server/routes/enrollment_api_key/handler.ts:53:20)
    at Router.handle (/Users/jfsiii/work/kibana/src/core/server/http/router/router.ts:273:30)
    at handler (/Users/jfsiii/work/kibana/src/core/server/http/router/router.ts:228:11)
    at exports.Manager.execute (/Users/jfsiii/work/kibana/node_modules/@hapi/hapi/lib/toolkit.js:60:28)
    at Object.internals.handler (/Users/jfsiii/work/kibana/node_modules/@hapi/hapi/lib/handler.js:46:20)
    at exports.execute (/Users/jfsiii/work/kibana/node_modules/@hapi/hapi/lib/handler.js:31:20)
    at Request._lifecycle (/Users/jfsiii/work/kibana/node_modules/@hapi/hapi/lib/request.js:370:32)
    at Request._execute (/Users/jfsiii/work/kibana/node_modules/@hapi/hapi/lib/request.js:279:9) {
  shortMessage: 'Expected AND, OR, end of input but "\\" found.'
```

the `kuery` value which causes the `KQLSyntaxError` is
```
policy_id:\"d6a93200-b1bd-11eb-90ac-052b474d74cd\" AND name:with\\ spaces*
``` 

a value without spaces, e.g. `no_spaces` 

```
policy_id:\"d6a93200-b1bd-11eb-90ac-052b474d74cd\" AND name:no_spaces*
```

is converted to this query object

```
{
  "bool": {
    "filter": [
      {
        "bool": {
          "should": [
            {
              "match_phrase": {
                "policy_id": "d6a93200-b1bd-11eb-90ac-052b474d74cd"
              }
            }
          ],
          "minimum_should_match": 1
        }
      },
      {
        "bool": {
          "should": [
            {
              "query_string": {
                "fields": [
                  "name"
                ],
                "query": "no_spaces*"
              }
            }
          ],
          "minimum_should_match": 1
        }
      }
    ]
  }
```

I tried some other approaches for handling the spaces based on what I saw in the docs like `name:"\"with spaces\"` and `name:(with spaces)*`but they all failed as well, like

```
KQLSyntaxError: Expected AND, OR, end of input but "*" found.
policy_id:"d6a93200-b1bd-11eb-90ac-052b474d74cd" AND name:(with spaces)*
-----------------------------------------------------------------------^
    at Object.fromKueryExpression (/Users/jfsiii/work/kibana/src/plugins/data/common/es_query/kuery/ast/ast.ts:52:13)
    at listEnrollmentApiKeys (/Users/jfsiii/work/kibana/x-pack/plugins/fleet/server/services/api_keys/enrollment_api_key.ts:37:69)
    at Object.generateEnrollmentAPIKey (/Users/jfsiii/work/kibana/x-pack/plugins/fleet/server/services/api_keys/enrollment_api_key.ts:166:31)
    at processTicksAndRejections (internal/process/task_queues.js:93:5)
    at postEnrollmentApiKeyHandler (/Users/jfsiii/work/kibana/x-pack/plugins/fleet/server/routes/enrollment_api_key/handler.ts:53:20)
    at Router.handle (/Users/jfsiii/work/kibana/src/core/server/http/router/router.ts:273:30)
    at handler (/Users/jfsiii/work/kibana/src/core/server/http/router/router.ts:228:11)
    at exports.Manager.execute (/Users/jfsiii/work/kibana/node_modules/@hapi/hapi/lib/toolkit.js:60:28)
    at Object.internals.handler (/Users/jfsiii/work/kibana/node_modules/@hapi/hapi/lib/handler.js:46:20)
    at exports.execute (/Users/jfsiii/work/kibana/node_modules/@hapi/hapi/lib/handler.js:31:20)
    at Request._lifecycle (/Users/jfsiii/work/kibana/node_modules/@hapi/hapi/lib/request.js:370:32)
    at Request._execute (/Users/jfsiii/work/kibana/node_modules/@hapi/hapi/lib/request.js:279:9) {
  shortMessage: 'Expected AND, OR, end of input but "*" found.'
```

So I logged out the query object for a successful request, and put that in a function

```
{
  "query": {
    "bool": {
      "filter": [
        {
          "bool": {
            "should": [
              {
                "match_phrase": {
                  "policy_id": "d6a93200-b1bd-11eb-90ac-052b474d74cd"
                }
              }
            ],
            "minimum_should_match": 1
          }
        },
        {
          "bool": {
            "should": [
              {
                "query_string": {
                  "fields": [
                    "name"
                  ],
                  "query": "(with spaces) *"
                }
              }
            ],
            "minimum_should_match": 1
          }
        }
      ]
    }
  }
}
```


### Checklist
- [x] [Unit or functional tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html) were updated or added to match the most common scenarios
2021-05-13 17:32:14 -04:00
Mike Côté bb7057c343
Rename alert status OK to Recovered and fix some UX issues around disabling a rule while being in an error state (#98135)
* Fix UX when alert is disabled and in an error state

* Reset executionStatus to pending after enabling an alert

* Renames alert instance status OK to Recovered

* Fix end to end test

* Update doc screenshot

* Fix confusing test name

* Remove flakiness in integration test

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-13 14:16:36 -04:00
Dario Gieselaar bdde884d09
[RAC] Decouple registry from alerts-as-data client (#98935) 2021-05-13 17:12:47 +02:00
Justin Kambic e3f0afa4e0
Move functional tests off of legacy es client. (#99801)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-12 15:21:22 -04:00
Quynh Nguyen e99cfb5c0b
[ML] Stabilize anomaly chart embeddable tests (#99955)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-12 13:15:52 -05:00
Thom Heymann 4e5df8cf20
Handle session timeout and user activity (#98461)
* Handle session timeout and user activity

* Added suggestions form code review

* Fix i18n errors

* Moved session timeout calculation to server side

* fixed tests

* Added suggestions from code review

* fix types

* Removed unecessary response interceptor and improved copy

* Handle scenario when session does not exist correctly

* Do not show warning again if previously dismissed

* Added suggestions from code review

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-12 17:33:10 +01:00
Nathan Reese b097385707
[Lens] visualize in maps button (#98677)
* [Lens] visualize in maps button

* clean up dependency injection as suggested

* add custom workspace render for geo fields

* tslint and finish drag and drop for geo field

* convert react class to function component

* prevent page reload when clicking visualize in maps button

* filter allFields instead of using condition to populate fieldTypeNames to fix tslint

* clean up UI

* fix jest test

* globe illustration

* UI cleanup

* functional test

* Update x-pack/plugins/lens/public/editor_frame_service/editor_frame/workspace_panel/geo_field_workspace_panel.tsx

Co-authored-by: Michael Marcialis <michael@marcial.is>

* Update x-pack/plugins/lens/public/editor_frame_service/editor_frame/workspace_panel/geo_field_workspace_panel.scss

Co-authored-by: Michael Marcialis <michael@marcial.is>

* Update x-pack/plugins/lens/public/editor_frame_service/editor_frame/workspace_panel/geo_field_workspace_panel.tsx

Co-authored-by: Michael Marcialis <michael@marcial.is>

* Update x-pack/plugins/lens/public/editor_frame_service/editor_frame/workspace_panel/geo_field_workspace_panel.scss

Co-authored-by: Michael Marcialis <michael@marcial.is>

* Update x-pack/plugins/lens/public/editor_frame_service/editor_frame/workspace_panel/geo_field_workspace_panel.scss

Co-authored-by: Michael Marcialis <michael@marcial.is>

* Update x-pack/plugins/lens/public/indexpattern_datasource/field_item.tsx

Co-authored-by: Michael Marcialis <michael@marcial.is>

* updated globe svg

* remove unused

* better message for drop zone screen reader

* Update x-pack/plugins/lens/public/editor_frame_service/editor_frame/workspace_panel/geo_field_workspace_panel.tsx

Co-authored-by: Michael Marcialis <michael@marcial.is>

* tslint

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Michael Marcialis <michael@marcial.is>
2021-05-12 09:54:34 -06:00
igoristic 6d263162f0
[Monitoring] Added missing cgroup memory (#99602)
* Added missing cgroup memory

* Fixed tests

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-12 11:24:05 -04:00
Robert Oskamp c44e5f75a3
[ML] Functional tests - increase module test coverage (#99758)
This PR adds a couple API integrations tests to get, recognize and setup modules.
2021-05-12 13:18:36 +02:00
Jean-Louis Leysens c22d9fd690
[Reporting] Relax save requirement for CSV reports (#99313)
* update requirement to save csv report in ui

* update expectation that CSV reporting is disabled for new discover searches

* update test expectations (again)

* refactor to using props-driven approach

* provide a fallback title

* refine title a bit more

* added component level test

* return ISO string with offset

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-12 10:32:51 +02:00
Lukas Olson 7617642bba
Add partial results to search examples demo (#96366)
* Add partial results to search examples demo

* Add functional test

* Move types into separate file and separate custom strategies

* Review feedback

* Update test

* Try to fix test

* Attempt to fix test

* Try to fix observable error

* Sanity check

* Fix test

* Another attempt

* Remove rxjs from strategy
2021-05-11 12:41:21 -07:00
Nathan Reese 5dbc73f1b4
[Maps] use deep equals for mapbox filter expression equals check (#99673)
* [Maps] use deep equals for mapbox filter expression equals check

* cleanup
2021-05-11 09:38:40 -06:00
Tyler Smalley 9da9b8d4b9
[kbn-es] Allow overriding of Java heap (#99517)
* [kbn-es] Allow overriding of Java heap

Fixes #99494

Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
2021-05-11 07:36:20 -07:00
Domenico Andreoli 2d05d9f802
Add CCS integration test for security rules (#99042) 2021-05-11 16:19:32 +02:00
Alison Goryachev 72c25ea10f
[Index Management] Unskip indices API integration test (#99379) 2021-05-11 08:53:16 -04:00
Kyle Pollich baf11e8749
[Fleet] Remove timestamp field from component template (#99619)
* Remove timestamp field from component template

Elasticsearch bug fixed upstream allows us to remove this field from the
template: elastic/elasticsearch/#58956

Closes #71095

* Remove timestamp field from functional test
2021-05-10 14:11:23 -04:00
Dominique Clarke 2f90e73569
[Uptime] remove settings flaky test comment (#99402)
* remove outdated comment
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-10 10:15:01 -04:00
Tiago Costa 8b77d7ae12
skip flaky suite (#99006) 2021-05-10 14:40:56 +01:00
Tim Sullivan f73da420ff
[Reporting] Update Puppeteer to version 8.0.0 and Chromium to r856583 (#98688)
* Update Puppeteer to 8.0.0

Updates Chromium to r856583
Links to new build of Linux headless_shell in the Kibana team GCS bucket
Links to main download site of Chromium for Mac and Windows
Removes Mac and Windows compatibility from the Chromium build scripts

* add functional tests for large dashboard

* ensure png comparison is working

* add test for large dashboard pdf

* update arm64 binary checksum

* update README

* more readme update

* Update x-pack/build_chromium/README.md

Co-authored-by: Jean-Louis Leysens <jloleysens@gmail.com>

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Jean-Louis Leysens <jloleysens@gmail.com>
2021-05-07 09:54:33 -07:00
James Gowdy 518da4daa1
[ML] Fixing route handler types and schemas (#98636)
* [ML] Fixing route handler types and schemas

* commenting out type error

* updates to fix functional tests

* updating jest test

* updating test expect

* fixing tests

* fixing test expect

* changes based on review

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-07 13:08:25 +01:00
spalger 822708b27c correctly skip flaky suite (#98249) 2021-05-06 15:56:42 -07:00
Jonathan Budzenski a643bb389d skip flaky test. #98249 2021-05-06 15:50:44 -05:00
Spencer 21c54d38c3
[ftr] auto assign ciGroupDocker to suites with dockerServers (#99393)
Co-authored-by: spalger <spalger@users.noreply.github.com>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-06 12:42:29 -07:00
John Dorlus a1954b4334
Changed Upgrade Assistant test to reflect hiding the UI (#96714)
* Added test to verify the UI changes for hiding the app.

* Running tests on repeat.

* Tests passed. Removing only clause to allow full suite to run.

* Skipping firefox.

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-06 12:59:59 -04:00
Robert Oskamp beaa4e78fb
[ML] Functional tests - reenable clone and edit tests for transform latest (#99306)
This PR fixes the data grid parsing and re-enables the clone and edit tests for transform latest.
2021-05-06 17:54:24 +02:00
Kevin Logan f2bb74e996
[Security Solution][Detections] Add linux artifact for exception lists (#99104) 2021-05-06 09:13:37 -04:00
Spencer 61eb3f0685
[ftr] validate that suites are not in multiple ciGroups (#99398)
* [ftr] validate that suites are not in multiple ciGroups

* remove unused import

* include filename in error message

* remove redundant ciGroup tags

* fix more duplicate ciGroups

Co-authored-by: spalger <spalger@users.noreply.github.com>
2021-05-05 14:50:07 -07:00
Tim Roes 792845fd75
Enable custom time ranges for saved searches (#99180)
* Enable custom time ranges for saved searches

* Add functional test

* Fix Typing

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-05 16:35:39 +02:00