- Fix the setup step (the process has changed now that we're using
pytest)
- Skip tests that are unstable
- Make better use of build caching
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
- Support all basic pattern forms: file, directory, *, ?, !
- Fix handling of wildcard patterns and subdirectories - `*/a.py` should
match `foo/a.py`, but not `foo/bar/a.py`
- Fix handling of directory patterns with a trailing slash - make sure
they're handled equivalently to those without one
- Fix handling of custom Dockerfiles - make sure they go in the tarball
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
- There was a typo (".dockerginore"), which meant that the exclusion of
the .dockerignore file itself wasn't being tested.
- Some of the file names were non-descriptive.
- The test was inspecting the output of the build process, rather than
running 'ls' in a new container, which meant it was full of extra
output, and would fail when there was a cache hit.
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
By having this hardcoded list of log drivers, it is a bottleneck
to us supporting more log drivers.
The daemon already validates if a log driver is valid or not, so rather
than duplicating that validation, let's pass the log_driver along.
This allows support for new/more log drivers as they become supported
in docker without having to wait for both docker-py and docker-compose
to support them.
Keeping the current list of log driver types for backwards compatibility.
Signed-off-by: Mazz Mosley <mazz@houseofmnowster.com>
By using `json-file` as the use case we can run this without needing
to be on a machine with syslog installed.
Even if syslog was installed, this test was still failing as the
`log_opt` of 'key1' is an invalid option.
This test is slightly different style to the others, it hopefully
includes an example of how to space out tests for increased readability,
we construct our tests in 3 phases(generally) and include a space imbetween
them:
- setup
- perform action
- assertions
Expanded variable names is important for readability/clarity. Also
reduced the number of assertions to focus on the logic we're testing.
Signed-off-by: Mazz Mosley <mazz@houseofmnowster.com>