Update run script for services example

This commit is contained in:
Roman Mogilatov 2016-10-11 17:45:56 +03:00
parent dde52a5d0f
commit c93b6fcfdf
2 changed files with 3 additions and 26 deletions

View File

@ -147,17 +147,11 @@ several IoC containers for some example application:
auth_service=Services.auth,
photos_service=Services.photos)
Next example demonstrates run of dependency injection example application
defined above:
Next example demonstrates run of example application defined above:
.. code-block:: python
"""Run dependency injection example application.
Instructions for running:
python run.py 1 secret photo.jpg
"""
"""Run example application."""
import sys
import logging
@ -192,12 +186,6 @@ defined above:
# photos_service=example.services.Photos(logger=logger,
# db=database,
# s3=s3))
#
# Output:
#
# User 1 has been found in database
# User 1 has been successfully authenticated
# Photo photo.jpg has been successfully uploaded by user 1
Alternative definition styles of providers
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

View File

@ -1,9 +1,4 @@
"""Run dependency injection example application.
Instructions for running:
python run.py 1 secret photo.jpg
"""
"""Run example application."""
import sys
import logging
@ -38,9 +33,3 @@ if __name__ == '__main__':
# photos_service=example.services.Photos(logger=logger,
# db=database,
# s3=s3))
#
# Output:
#
# User 1 has been found in database
# User 1 has been successfully authenticated
# Photo photo.jpg has been successfully uploaded by user 1