elastic / elastic/elastic-package
Some commands are not generating xUnit files when they fail
- Dominant language
- Go
- Stars
- 72
- Forks
- 141
- Avg merge
- 19h 42m
- Merged PRs (30d)
- 55
Description
Some commands are not generating xUnit when they fail. For instance, if the package installation fails these commands would not generate any xUnit report:
- `elastic-package install`
- `elastic-package test asset`
- `elastic-package test system`
- `elastic-package test policy`
This was detected in Buildkite builds like where `hpe_aruba_cx` package fails because it uses a processor that is not available in the `basic` Subscription. Example: https://buildkite.com/elastic/integrations/builds/27354
This causes that these errors are not reported to the teams owning the package via GitHub issues in the daily CI jobs.
It needs to be reviewed at least all sub-commands of `elastic-package test` to ensure that these kind of failures are reported as part of the xUnit files.
It could be added a new environment variable that if it is set, all commands generate a test xUnit report. It needs to be validated that there are not duplicated errors in those reports if that variable is set.
Maybe it is also needed to revisit the CI pipelines running in the integrations repository. At least, in the step when the package is installed via the `elastic-package install` command.
Relates:
https://github.com/elastic/integrations/issues/14244
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by tracing xUnit generation in elastic-package install and each listed elastic-package test sub-command, using the failing package-install scenario as the reproduction. Review the integrations CI step that runs elastic-package install; done means failures from these commands appear in xUnit reports without duplicated errors.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- ci-cd, cli, testing-qa
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100