compose/tests/unit
Ben Thorner a6b602d086 Support attaching to dependencies on up
When using the 'up' command, only services listed as arguments are
attached to, which can be very different to the 'no argument' case
if a service has many and deep dependencies:

   - It's not clear when dependencies have failed to start. Have to run
'compose ps' separately to find out.
   - It's not clear when dependencies are erroring. Have to run 'compose
logs' separately to find out.

With a simple setup, it's possible to work around theses issue by
using the 'up' command without arguments. But when there are lots of
'top-level' services, with common dependencies, in a single config,
using 'up' without arguments isn't practical due to resource limits
and the sheer volume of output from other services.

This introduces a new '--attach-dependencies' flag to optionally attach
dependent containers as part of the 'up' command. This makes their logs
visible in the output, alongside the listed services. It also means we
benefit from the '--abort-on-container-exit' behaviour when dependencies
fail to start, giving more visibility of the failure.

Signed-off-by: Ben Thorner <ben.thorner@digital.cabinet-office.gov.uk>
2020-01-16 13:41:54 +00:00
..
cli Support attaching to dependencies on up 2020-01-16 13:41:54 +00:00
config Merge pull request #6873 from frenzymadness/pytest_compatibility 2020-01-10 17:09:33 +01:00
__init__.py Split tests into unit and integration 2014-04-25 22:58:21 +01:00
cli_test.py Fix one-off commands for "restart: unless-stopped" (fixes #6302) 2018-11-26 23:23:56 +01:00
container_test.py Pin test images on a non rolling tag 2019-07-18 11:10:37 +02:00
network_test.py Prevent KeyError when remote network labels are None. 2019-09-05 21:36:10 +02:00
parallel_test.py Revamp ParallelStreamWriter to fix display issues. 2018-03-07 15:22:38 +01:00
progress_stream_test.py fix race condition after pulling image 2019-01-09 23:14:12 +01:00
project_test.py Cleanup all open files 2019-10-28 15:36:05 +01:00
service_test.py Decode APIError explanation to unicode before usage 2020-01-06 16:00:34 +01:00
split_buffer_test.py Replace unittest-style asserts with pytest asserts 2018-01-04 14:38:28 -08:00
timeparse_test.py Use stop grace period for container stop. 2016-11-16 12:12:28 -05:00
utils_test.py utils: Fix typo in unique_everseen. 2018-09-27 14:17:32 +02:00
volume_test.py Add support for v3.4 files and custom volume names 2017-08-11 11:48:00 -07:00