Make DeactivationOnIdle behaviour on POCO grain consistent#173
Make DeactivationOnIdle behaviour on POCO grain consistent#173rinkeb wants to merge 1 commit intoOrleansContrib:mainfrom
Conversation
|
I agree that it should be possible to assert for calls to I don't think this is an appropriate interface, though. It shouldn't be a requirement for TestKit consumers to have to cast objects to get to the mock object. In the other path, there's a mock object for IGrainRuntime. I also don't think TestKit consumers should have to figure out which of these deactivation mocks to assert on based on their grain implementation pattern. |
Well, for me its not really about asserting. I just want to be able to call I just mimicked the solution of #9 to have a similar way to validate the behaviour. Not sure about better options, as i'm not that familiar with the code base. |
|
Never mind, i migrated to |
The current behaviour of a call to
DeactivateOnIdledepends on whether the grain is a normal grain (derivingGrain) or a POCO grain (implementingIGrainBase). When called on the first a mocked implementation (noop) is called, while on the latter aNotImplementedExceptionis thrown.In my opinion the choice for either is an implementation detail and should not result in different grain behaviour.
This pull request proposes a change to make the behaviour of the latter consistent with the former.