pytest-docker-py

Easy to use, simple to extend, pytest plugin that minimally leverages docker-py.


Keywords
pytest, plugin, docker-py, docker, pytest-plugin, python36
License
Apache-2.0
Install
pip install pytest-docker-py==1.1.3

Documentation

pytest-docker-py Build Status Coverage Status

  • Easy to use, simple to extend, external pytest plugin that minimally leverages docker-py.

1. Introduction

  • A plugin that keeps it simple and lets you:

    • pull images - if not already pulled.
    • start containers - with various, optional, parameters - i.e. ports; networks; volumes; commands.
    • stop containers.
  • See test/integration/test_plugin.py for a working example.

2. Installation

  • pip install pytest-docker-py

or

then

3. Development / PR - on Ubuntu 18.04

3.1. Create Virtual Environment

  • ./create-venv.sh

3.2. Unit Tests

  • ./run-unit-tests.sh

3.3. Integration Tests

  • ./run-integration-tests.sh