Metadata-Version: 2.1
Name: pytel-inject
Version: 0.4
Summary: Injection of dependencies for python 3
Home-page: https://github.com/mattesilver/pytel
License: Apache-2.0
Keywords: injection-of-dependencies
Author: Rafal Krupinski
Requires-Python: >=3.7,<4.0
Classifier: License :: OSI Approved :: Apache Software License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.7
Classifier: Programming Language :: Python :: 3.8
Project-URL: Repository, https://github.com/mattesilver/pytel
Description-Content-Type: text/x-rst

A bag of objects for Python
===========================

.. image:: https://img.shields.io/pypi/v/pytel-inject.svg?style=flat
    :target: https://pypi.org/project/pytel-inject/

.. image:: https://travis-ci.com/mattesilver/pytel.svg
  :target: https://travis-ci.com/mattesilver/pytel

.. image:: https://codecov.io/gh/mattesilver/pytel/branch/master/graph/badge.svg
  :target: https://codecov.io/gh/mattesilver/pytel

For when your object graph is too big

.. code-block:: python

    class A:
        def __init__(self, b: B):
            self.b = b

    class B:
        pass

    svc = {
        'a': A,
        'b': B,
    }
    context = Pytel(PytelContext(svc))
    assert context.a.b == context.b

See `usage <https://github.com/mattesilver/pytel/blob/master/tests/pytel/test_usage.py>`_ for more cases

