chore(dev): prevent tests from running if a command fails to run #1825
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Running tests (
make test
) withoutdocker
installed result in the script silently failing to start docker, followed by a lot of failing tests (because no database is available). This change makes it more obvious that docker should be installed for the tests to run.This also allows to run tests (and the dev env) without actually needing docker, provided that a Postgres URI is provided. The tests relying heavily on timing of operations, being able to run them in a non virtualized environment (esp. from MacOS), makes their execution much more reliable and fast.
Testing
packages/pds
aloneWith Docker (notice the 2.5Gb of RAM used by the VM):
The failing test is due to a race condition (they do run successfully from time to time).
Without Docker (pg & redis installed on the host):