I couldn't find an example where something like the following is mocked
public Something SomeMethod(Input input, string foo, out Details bar);
I'd like to moq the result of 'SomeMethod' and also the out parameter bar.
Thanks for your help.
Phil
PS Please answer to my e-mail address directly since I'm not
registered on this list.
Hi Daniel,
Does MoQ not support out or ref arguments as a matter of principal or
because it's technically impractical?
I'm sure many people find out or ref arguments to be a valid design
decision when designing internal libraries for advanced consumers (and
even when implementing public libraries for novices ;) )
Thanks,
Uri
On Apr 29 2008, 1:29 am, "Daniel Cazzulino" <dan...@cazzulino.com>
wrote:
> MoQ does not currently support out or ref arguments.
>
> There's an explicit VS code analysis feature that warns against using out
> parameters:http://msdn2.microsoft.com/en-us/library/ms182131.aspx
>
> do you own the library you're testing or is it a third party one? have you
> evaluated making the out value part of the return value?
>
> On Mon, Apr 28, 2008 at 12:05 PM, Philippe Lavoie <philippe.lav...@gmail.com>