mirror of
https://github.com/ets-labs/python-dependency-injector.git
synced 2024-11-22 09:36:48 +03:00
Fix provider overriding tests
This commit is contained in:
parent
d51f2fa79a
commit
043665f8e5
|
@ -82,7 +82,9 @@ class ProviderTests(unittest.TestCase):
|
|||
|
||||
def test_override_with_not_provider(self):
|
||||
"""Test provider overriding with not provider instance."""
|
||||
self.assertRaises(errors.Error, self.provider.override, object())
|
||||
obj = object()
|
||||
self.provider.override(obj)
|
||||
self.assertIs(self.provider(), obj)
|
||||
|
||||
def test_last_overriding(self):
|
||||
"""Test getting last overriding provider."""
|
||||
|
|
Loading…
Reference in New Issue
Block a user