* Move enzyme & misc test helpers out of __mocks__/ and into new test_helpers/
They're not technically mocks since nothing is being mocked, so we should move them into a test_helpers folder for specificity & organization
* Move React Router mocks into its own separate folder/import
This was part of the initial feedback, that it was unclear why importing something for Kea in __mocks__/index.ts was mocking react router along for the ride. Separating this out makes things clearer and imports more explicit
+ add some handy new mock useX jest.fn()s helpers, so we're not doing `useParams() as jest.Mock` errywhere
* Move Kea & logic mocks/helpers into kea_logic subfolder
- for organization
NOTE: It can't be a plain kea/ folder because then Jest automatically mocks the `kea` module itself kea 🤦
* Fix type failures
- Caused by switch from any to unknown (changed back to any + added a .test_helper suffix exclusion for any)
* Fix Enterprise Search tests/imports
- I checked all application folders but this one, whoops
* PR feedback: comment copy
* Update tests/files added since PR open with new import locations
* Fix misc react router typing
- null not being type-able as a boolean
- forgot to remove various useParam imports after adding mockUseParams
+ misc unused kea import, probably added while debugging kea mocks
# Conflicts:
# x-pack/plugins/enterprise_search/public/applications/app_search/components/crawler/crawler_overview.test.tsx
# x-pack/plugins/enterprise_search/public/applications/app_search/components/crawler/crawler_overview_logic.test.ts
* WIP
* Storing start, duration and end in alert state
* Writing to event log
* Updating unit tests
* Adding unit tests
* Fixing uuid in tests
* Updating functional test
* Adding functional test
* Removing console logs
* Fixing unit tests
* PR fixes
* Removing uuid from alert information
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: ymao1 <ying.mao@elastic.co>
* [Index Patterns] Runtime fields CRUD REST API (#101164)
Part of index pattern REST API
# Conflicts:
# docs/development/plugins/data/public/kibana-plugin-plugins-data-public.indexpattern.md
# docs/development/plugins/data/server/kibana-plugin-plugins-data-server.indexpattern.md
* fix bad docs merge
* Remove RecursiveReadonly wrapper on public API items
* Remove Pick and export some types that are part of the public API
* Udpate api docs
* Export API items that are part of the public API
* Add extra comments
* update api docs
Co-authored-by: Stacey Gammon <gammon@elastic.co>
* Refactor phase types (mostly moving imports)
* Refactor phase types (mostly moving imports)
* Renamed a type for consistency and replaced more hard coded strings with types
* Fixed remaining references to the deleted MinAgePhase
* ✨ New summary row feature for datatable
* ✨ Allow empty strings behind flag + tests
* 🐛 Address the transition problem + refactor
* ✅ Add some unit tests
* ✅ Add first functional tests
* 👌 first feedback addressed
* ✨ Make it handle numeric array values
* 📝 Improved message
* ✅ Fix functional test
* 🔥 Remove warning message for last value
* 🚨 Remove unused import
* 🐛 Fix a bug with last value
* 👌 Integrated feedback
* 💄 Migrated to combobox
* ✅ Fix unit tests + restore right data-test-id
* 🏷️ Fix type issue
* 👌 Address all issues reported
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Marco Liberati <dej611@users.noreply.github.com>
* Add back button when to the event filters list. Isolated back to external app button to be used as generic component
* Adds unit tests for back button
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: David Sánchez <davidsansol92@gmail.com>
* Changes multilang for add endpoint event filter action on events tab
* Changes more multilangs and display name error only when needed
* Changes variable names and aria labels to be consistent with namings
* Fixes unit test due multilang changes
Co-authored-by: David Sánchez <davidsansol92@gmail.com>
## Summary
Adds runtime field tests with skips around the tests that we do not support just yet.
* Adds tests around corner cases involving ".", "..", ".foo", "foo.", etc...
* Adds tests around overriding values from the runtime fields within the source document
* Adds tests around ambiguity for when we override an array in a runtime field
* Fixes minor wording around previous tests
* Fixes one line string when we do testing in one area
### 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
Co-authored-by: Frank Hassanabad <frank.hassanabad@elastic.co>
* Added APM PHP agent to the list of agent names to include it into the agent telemetry collection
* put php label into alphabetical order
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Alexander Wert <AlexanderWert@users.noreply.github.com>
* Add explicit security types
* Remove sessionTimeout, seems unused
* add comments
* Add comments and fix test since removing the unused APIs
* remove unused import
* wording cleanup
* Export some types that are part of the public API but not exported
* more improvements for api docs
* update security docs
* Update x-pack/plugins/security/public/nav_control/nav_control_service.tsx
Co-authored-by: Larry Gregory <lgregorydev@gmail.com>
* Update x-pack/plugins/security/public/nav_control/nav_control_service.tsx
Co-authored-by: Larry Gregory <lgregorydev@gmail.com>
* Update x-pack/plugins/security/public/plugin.tsx
Co-authored-by: Larry Gregory <lgregorydev@gmail.com>
* Update x-pack/plugins/security/public/plugin.tsx
Co-authored-by: Larry Gregory <lgregorydev@gmail.com>
* remove unneccessary readonly prefix
* Update all api docs
Co-authored-by: Larry Gregory <lgregorydev@gmail.com>
# Conflicts:
# api_docs/data.json
# api_docs/data_index_patterns.json
# api_docs/data_search.json
# api_docs/deprecations.mdx
# api_docs/licensing.json
# api_docs/lists.json
# api_docs/triggers_actions_ui.json
# api_docs/usage_collection.json
In 7.x, when saved objects point to an index and not an alias it will
assume it's pre-6.8 and perform a legacy migration. This causes issues
with the removal of oss builds. This update prevents that from happening
by using an alias.
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
Co-authored-by: Tyler Smalley <tyler.smalley@elastic.co>
* make `Endpoint.configuration` and `Endpoint.state` optional in the Host Metadata
* Set types in generator to also be optional
Co-authored-by: Paul Tavares <56442535+paul-tavares@users.noreply.github.com>
* Update documentation.tsx
* Update documentation.tsx
* Update documentation.tsx
* fix type issue
* Noticed a lack of a space in the screenshot
Co-authored-by: Stacey Gammon <gammon@elastic.co>