* ui/persisted_state 👉 src/plugins/visualizations
Part of #46926
* fix JEST
* remove sinon from tests
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
* Use diagnostics-enable action in the workflow. Issue: #56526
* Update workflow to use v1.0.2 of the action
* Adding a new test workflow that uses a personal access token
* Remove an extra coma
* Updated project-assigner action version and access key
* Deleted the test workflow
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
* Add KQL filtering
* Schema updates
* Cursor-based pagination
* Add alert detail GET api
* A little refactoring ;)
* Add KQL filtering
* Render SearchBar that provides suggestions and executes search
* Schema updates
* Cursor-based pagination
* Bug fix with search_after type
* hook up filters, trying date range
* Multi-filter support
* Add rison encoding/decoding on the backend
* Wire up front-end for new GET request
* tiny bug fix
* use redux for state, disable saved queries
* Remove SearchBar UI code
* Remove Search Bar UI Part 2
* test 1
* test 2
* Finish integrating refactor work
* Fix fromIndex calculation
* Address feedback
* More tweaks
* Add some tests, round 1
* Add Direction enum
* Add next and prev urls for alert details
* refactor
* fixes
* No more AlertDataWrapper, less Maybe types
* change @timestamp to type number, redefine AlertListState
* moved pagination classes, moved types to alerts top level
* remove fake data mappings file
* Fix data location
* remove Maybe type, prev and next have type 'string | null'
* fix functional tests
* Create immutable AlertEvent type and an AlertMetadata type
* test updates
* make tests werk
* Address PR feedback
* No Date Immutable
* Fix test params
* Fix test type-check
Co-authored-by: Pedro Jaramillo <peluja1012@gmail.com>
Address all of the requests in #54182.
Also add a story for the Cytoscape component that shows most of these changes.
Fixes#54182.
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
## Summary
* Adds an exact function which allows us to do exact validation rather than allowing arbitrary keys to go through
* Adds a type dependency for parts of validation (gives us feature parity with joi.when())
* Adds several hand spun validations/codecs
* Adds several utilities such as a printer for error validations
### Checklist
Delete any items that are not applicable to this PR.
- [x] [Unit or functional tests](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#cross-browser-compatibility) were updated or added to match the most common scenarios
* chore: move gitignore to the cypress directory
* chore: ignore more test files
* fix: do not check the Loading Message
It seems not relevant to the main purpose of these tests
* chore: use cypres + webpack + cucumber scaffolding
See https://github.com/TheBrainFamily/cypress-cucumber-webpack-typescript-example
* chore: add eslint and prettier for code linting
* feat: convert existing Cypress test into BDD style
* feat: add support for using proper Node version in MacOSX
* chore: use tslint
* chore: use old layout
We are keeping cypress as rootDir to follow project's structure. On the other hand,
having a second cypress directory at the 2nd level is the default structure, as shown
in the examples:
- https://github.com/TheBrainFamily/cypress-cucumber-webpack-typescript-example
- a240054d7f/examples/preprocessors__typescript-webpack
* chore: remove prelint script meanwhile we fix TS lint
* chore: move test results to a specific directory
* chore: rename variable following old code
* chore: remove non-needed lints, as we are going to use kibana build
* chore: import snapshot function from cypress
* chore: add readFile utils back from a bad removal
* chore: change format of JSON spec file
It was automatically changed by tests
* chore: move CI directory to the proper layout in order for Jenkins to work
* chore: store test-results from proper dir on Jenkins
* chore: store artifacts properly on Jenkins
* Fix type issues
* chore: rename test application to e2e (end-to-end)
We are keeping the build system within the test application, isolating dependencies
* docs: reorganise docs for APM UI e2e tests
* fix: Use proper cypress support file
* chore: use existing NPM script for running cypress on CI
* chore: update paths in CI scripts
* docs: document how the CI runs the tests
* chore: use Node 10 for tests
* chore: Use kibana's Node version for tests
* chore: run yarn install
* docs: update docs
* fix: path was wrong
* docs: fix paths and flags used to load data
* docs: elasticsearch fix flag
* docs: Bootstrap kibana before running it
* docs: remove outdated info
* chore: move background steps to the scenario
This would avoid not reading the background when the number of scenarios grows
Co-authored-by: Dario Gieselaar <d.gieselaar@gmail.com>
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
* Migrate kbn_top_nav.js to kibana_legacy
* Wrap TopNavMenu into i18nContext
* Move the kbnTopNav directive definition to kibana_legacy and remove ui/kbn_top_nav
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
* [Metrics UI] Add custom metrics interface to Inventory View
* WIP
* Adding workflows for editing custom metrics
* Polishing visual design
* Removing extra text
* Fixing types and return values
* fixing i18n
* Adding aria labels for clearity
* Changing custom group by to match same width as custom metric
* updating integration test for custom metrics
* Fixing type def
* [Maps] add Top term aggregation
* update pew-pew source to handle terms agg
* make helper function for pulling values from bucket
* update terms source
* better join labels
* categoricla meta
* remove unused constant
* remove unused changes
* remove unused constant METRIC_SCHEMA_CONFIG
* update jest expect
* fix auto complete suggestions for top term
* get category autocomplete working with style props from joins
* pluck categorical style meta with real field name
* mock MetricsEditor to fix jest test
* review feedback
* es_agg_utils.js to es_agg_utils.ts
* typing updates
* use composit agg to avoid search.buckets limit
* i18n update and functional test fix
* stop paging through results when request is aborted
* remove unused file
* do not use composite agg when no terms sub-aggregations
* clean up
* pass indexPattern to getValueAggsDsl
* review feedback
* more review feedback
* ts-ignore for untyped imports in tests
* more review feedback
* add bucket.hasOwnProperty check
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
* Factor our the license checking logic and messaging to common
* Add licensing plugin as a dependency of the APM plugin
* Throw a forbidden error on the server if trying to access the service map routes
* Converted brush event to TS. Migrated tests to "jest" way and optimiz
* Removed unused definition in interface. Revert changes related to import deserializeAggConfig.
Co-authored-by: Alexey Antonov <alexwizp@gmail.com>
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
* es-archiver call _migrate endpoint instead of creating a migrator
* fix crlf....
* use promise instead of callback accessor
* attempt with disabled authent
* enable security again
* set mapping to dynamic before calling migration endpoint
* rename space data from non-spaced tests
* add documentation on the `rerun` flag
* create router with the `/api/saved_objects` prefix
* add unit test about strict mapping
* add integration test on migrate endpoint
* wrap route handler with handleLegacyErrors
* add remark about limitations of the rerun flag
* Apply suggestions from code review
Co-Authored-By: Aleh Zasypkin <aleh.zasypkin@gmail.com>
* do not return detailed index result
* add access tag to migrate route
* use /internal prefix for migrate endpoint
* fix integ tests
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
Co-authored-by: Josh Dover <me@joshdover.com>
Co-authored-by: Aleh Zasypkin <aleh.zasypkin@gmail.com>
* Refactor the all rules page to be easier to test
* review with Garrett
* bring back utility bar under condition
* fix bugs tags and allow switch to show loading when enable/disable rule
* fix rules selection when trigerring new rules
* fix imports/exports can only use rule_id as learned today
* review I
* Add async search strategy
* Add async search
* Fix async strategy and add tests
* Move types to separate file
* Revert changes to demo search
* Update demo search strategy to use async
* Add cancellation to search strategies
* Add tests
* Simplify async search strategy
* Move loadingCount to search strategy
* Update abort controller library
* Bootstrap
* Abort when the request is aborted
* Add utility and update value suggestions route
* Fix bad merge conflict
* Update tests
* Move to data_enhanced plugin
* Remove bad merge
* Revert switching abort controller libraries
* Revert package.json in lib
* Move to previous abort controller
* Fix test to use fake timers to run debounced handlers
* Revert changes to example plugin
* Fix loading bar not going away when cancelling
* Call getSearchStrategy instead of passing directly
* Add async demo search strategy
* Fix error with setting state
* Update how aborting works
* Fix type checks
* Add test for loading count
* Attempt to fix broken example test
* Revert changes to test
* Fix test
* Update name to camelCase
* Fix failing test
* Don't require data_enhanced in example plugin
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
Until these are officially supported in new platform, it's best to not
rely on this behavior. We can achieve roughly the same functionality
with a GET request. Modifies the existing script accordingly, in case
anyone's still using it.
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
* Revert "Temporarily removes kbn-optimizer cache key tests (#58318)"
This reverts commit e64eff0a3d.
* [kbn-optmizer] avoid mocking fs exports
* overwrite ciGroup script to support jest in flaky testing job
* limit jest workers to 3 so that concurrent runners have space to operate
* Revert "limit jest workers to 3 so that concurrent runners have space to operate"
This reverts commit 1a2f882f6d.
* Revert "overwrite ciGroup script to support jest in flaky testing job"
This reverts commit 548db61722.
* use links instead of click handlers when switching spaces
* remove unused imports
* remove use of deprecated injectedMetadata service
* simplify SpacesManager constructor
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>