forked from meltano/meltano
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
test: Randomize Pytest runs (meltano#6695)
* test: Randomize Pytest runs This PR adds a dependency on `pytest-randomly`, which seeds randomness in our test runs, and randomizes the order the tests are run in. The randomness introduced by this plugin can be replicated using the `--randomly-seed` argument that is printed out for each Pytest run. Running the tests in a random order helps to ensure they do not depend on tests that were run previously. This generally makes the test suite more robust, and also will allow us to run the tests in parallel using `pytest-xdist` - see meltano#6157 Most of the pre-existing implicit dependencies between tests have been addressed by making them explicit with `order` marks provided by the `pytest-order` plugin. This is not the cleanest approach (it would be better if there were no dependencies between our tests), but it should be sufficient to realize most of the benefits, and is much faster than rewriting the tests to not have dependencies on other tests. Closes meltano#6300 * Install `pytest-randomly` and `pytest-order` in Nox session * Set `--randomly-seed` in `noxfile.py` Because of how Nox collects output from Pytest, we cannot see the seed that `pytest-randomly` set in CI. We can set it outselves in `noxfile.py` so that it is printed out in CI. * Increase test fixture SQLAlchemy connection pool size * Fix `test_analytics_json_is_created` * Fix `test_config_meltano` on Windows For whatever reason, `send_anonymous_usage_stats` may be `False` on Windows when this test is run. The test is still sound without that particular check, so we can simply omit it. * Fix intermittent SQLAlchemy `OperationalError` * Increase `pool_size` in `meltano.core.db.project_engine` * Warn about SQLAlchemy operational error properly * Use `pool_size` only when SQLAlchemy configuration supports it * Use SQLAlchemy `NullPool` * Remove commented-out code * Revert changes to `vacuum_db` * Fix `TestUIAvailableWorker::test_open_browser`
- Loading branch information
1 parent
d80b58f
commit ca3fdfd
Showing
33 changed files
with
187 additions
and
67 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.