ncraike / fang

Dependency injection system for Python
MIT License
15 stars 1 forks source link

Example for mocking dependencies #3

Open zachswift615 opened 8 years ago

zachswift615 commented 8 years ago

Could you give a brief example of mocking the dependencies in unit tests?

Is that what the ResourceProviderRegister.clear() method is for? To clear the providers to ensure you're not actually calling dependencies during testing?