Migrate remaining test files from *.js to *.ts #116415
Labels
discuss
DX
Issues related to Developer Experience
impact:needs-assessment
Product and/or Engineering needs to evaluate the impact of the change.
Team:Core
Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc
Team:Operations
Team label for Operations Team
technical debt
Improvement of the software architecture and operational architecture
I intentionally omitted the broad migration across the whole codebases since most of the plugins already rely on
*.ts
in the plugin codebase but keep functional tests in*.js
.One of the pain points working on #113950 was lots of problems in
./test
and./x-pack/test
folders caused by the lack of typings.There are 412
*.js
files in./test
and./x-pack/test
folders and lots of places that misuseany
(like it used to bees: any
here)kibana/x-pack/test/alerting_api_integration/spaces_only/tests/alerting/builtin_alert_types/es_query/create_test_data.ts
Line 19 in 3c8fa52
I’m wondering whether we should start working towards
*.js
files migration to*.ts
. We've already been tracking the number ofany
in the public API. Similarly, we could start tracking the number of*.js
files per team, which in turn, requires defining owners for all the functional tests.It isn't a critical problem. But it affects DX when someone (usually the Kibana Platform team) has to fix issues in an unfamiliar domain. For example, logic in
./test
andx-pack/test
do not have tests, and the only way to investigate an FTR failure is to debug it in runtime that is slow by design.cc @elastic/kibana-operations
The text was updated successfully, but these errors were encountered: