hrrr
This commit is contained in:
20
README.md
Normal file
20
README.md
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
# Dependancy Injection
|
||||||
|
|
||||||
|
## initialize
|
||||||
|
|
||||||
|
```shell
|
||||||
|
pip install -r requirements.txt
|
||||||
|
```
|
||||||
|
|
||||||
|
## run
|
||||||
|
|
||||||
|
```shell
|
||||||
|
python3 __main__.py
|
||||||
|
```
|
||||||
|
|
||||||
|
|
||||||
|
## run tests
|
||||||
|
|
||||||
|
```shell
|
||||||
|
python3 tests.py
|
||||||
|
```
|
||||||
5
tests.py
5
tests.py
@@ -1,3 +1,4 @@
|
|||||||
|
import unittest
|
||||||
from unittest import mock
|
from unittest import mock
|
||||||
|
|
||||||
import services
|
import services
|
||||||
@@ -27,3 +28,7 @@ def test_is_mail_send():
|
|||||||
|
|
||||||
email_service.send.assert_called_once_with("test@receiver", "test invoice")
|
email_service.send.assert_called_once_with("test@receiver", "test invoice")
|
||||||
invoice_service.create_invoice.assert_called()
|
invoice_service.create_invoice.assert_called()
|
||||||
|
|
||||||
|
|
||||||
|
if __name__ == '__main__':
|
||||||
|
unittest.main()
|
||||||
|
|||||||
Reference in New Issue
Block a user