StackStorm (aka "IFTTT for Ops") is event-driven automation for auto-remediation, incident responses, troubleshooting, deployments, and more for DevOps and SREs. Includes rules engine, workflow, 160 integration packs with 6000+ actions (see https://exchange.stackstorm.org) and ChatOps. Installer at https://docs.stackstorm.com/install/index.html
This PR has commits extracted from #6202 where I'm working on getting all of our unit tests to run under pants+pytest.
This PR adds dependency-related BUILD metadata required to run various tests. In general, this includes:
uses=[...]: Makes our pants-plugins/uses_services plugin check for running services before running the tests.
stevedore_namespaces=[...]: Includes all plugins of each type (each stevedore namespace) listed. For example, stevedore_namespaces=["st2common.runners.runner"] would make all runners available when running a set of tests.
entry_point_dependencies=[...]: A more fine-grained version of steveore_namespaces. Instead of including every plugin that provide a given type, this includes selected entry points. This is especially helpful for runner tests, so that noop_runner tests only require the noop runner, instead of all of the runners. This feature is part of pants 2.23. It is one of the reasons we updated to 2.23 alpha in #6229 instead of waiting for a stable release.
dependencies=[...]: some tests depend on various files that pants cannot infer based on pants dependencies. For example, when a test runs an action via the API, there is no import that tells pants which action the test needs.
resources(...): some tests needed files that were not covered by any of the BUILD targets, so I added the files as resources.
It can be beneficial to step through the commits. That will show you which tests needed the metadata.
This PR has commits extracted from #6202 where I'm working on getting all of our unit tests to run under pants+pytest.
This PR adds dependency-related BUILD metadata required to run various tests. In general, this includes:
uses=[...]
: Makes ourpants-plugins/uses_services
plugin check for running services before running the tests.stevedore_namespaces=[...]
: Includes all plugins of each type (each stevedore namespace) listed. For example,stevedore_namespaces=["st2common.runners.runner"]
would make all runners available when running a set of tests.entry_point_dependencies=[...]
: A more fine-grained version of steveore_namespaces. Instead of including every plugin that provide a given type, this includes selected entry points. This is especially helpful for runner tests, so thatnoop_runner
tests only require the noop runner, instead of all of the runners. This feature is part of pants 2.23. It is one of the reasons we updated to 2.23 alpha in #6229 instead of waiting for a stable release.dependencies=[...]
: some tests depend on various files that pants cannot infer based on pants dependencies. For example, when a test runs an action via the API, there is no import that tells pants which action the test needs.resources(...)
: some tests needed files that were not covered by any of the BUILD targets, so I added the files asresources
.It can be beneficial to step through the commits. That will show you which tests needed the metadata.