-
-
Notifications
You must be signed in to change notification settings - Fork 748
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Pants ci: Run self-check tests w/ venv generated by pants #6287
Conversation
…2ctl reload fails.
At least in GHA in some cases, the ps output is getting truncated, possibly respecting our COLUMNS=120 env var. This adds ww to the ps command to make it have unlimited width.
84c5a9d
to
d46b106
Compare
def setUp(self): | ||
super().setUp() | ||
# pre-condition: Make sure there is no test pollution | ||
sw_queues = self._get_sensor_watcher_amqp_queues( | ||
queue_name="st2.sensor.watch.covfefe" | ||
) | ||
# TODO: Maybe just delete any leftover queues from previous failed test runs. | ||
self.assertTrue(len(sw_queues) == 0) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This change is unrelated to this PR. This test failed for several runs, and now it is magically passing.
Apparently we still have some cross test pollution with data in RabbitMQ. So, I'll leave this here and next time we see the bug, hopefully we can figure out how to prevent that cross test pollution that can make tests randomly fail.
I'm wondering about having some pytest fixture handle cleaning up all exchanges/queues for the execution slot before running any tests. If we do that, then we'd need to make sure not to break the tests that use the full st2 cluster (started with tools/launchdev.sh
).
This adds a Pants-based CI job to run
st2-self-check
with a virtualenv generated by pants.I recommend reviewing each commit.
The largest chunk of this PR is in 12af930 where I add the GHA job that runs st2-self-check.
Everything else is minor cleanup (or bugfixes) of several random scripts and a test.
I can split the unrelated changes into a separate PR if needed, but they're fairly small, so I hope we can just include them here.