Added support to provide Spy dependencies#82
Added support to provide Spy dependencies#82krazykira wants to merge 1 commit intofabioCollini:masterfrom
Conversation
…p with partial mocking
Codecov Report
@@ Coverage Diff @@
## master #82 +/- ##
============================================
- Coverage 85.48% 84.86% -0.62%
Complexity 187 187
============================================
Files 12 12
Lines 565 575 +10
Branches 97 98 +1
============================================
+ Hits 483 488 +5
- Misses 57 61 +4
- Partials 25 26 +1
Continue to review full report at Codecov.
|
|
I was thinking about something different, a method like this one: This would be more generic, instead of just creating a spy it allows to create a new object that uses the original one. |
|
@fabioCollini i think the whole point was that i didn't want to create and provide the spy object otherwise i could have used e.g: If there is any other way to providing spy without creating the underline dependencies then i would be open to it. |
|
Sorry, I don't get your point but maybe my explanation was not clear. I was saying that a To obtain something similar for the dependent object another decorate invocation can be used. |
|
@fabioCollini yes that would be even better. But i don't have much clue on how to achieve that 😕 |
|
Hi, I have implemented it in this commit a261d93ea5, the modification is not too big and I have tried it in some tests. Can you try to use it (just use the commit as DaggerMock version) and give me a feedback? |
Note: Please let me know if you want me to update the Readme.md or if you want me to