How to break private method call from a Method Under Test in Microsoft Fakes Unit Testing?
<p>I tried for searching a lot regarding this but did not find any helpful information. And I'm stuck in below situation and seeking for help.</p>

<p>Below is my method which I want to test:</p>

<pre><code>public void MethodToTest()
    {
        this._app = this.GetApp(out this._pId);
    }

//here beelow method which is from the same class and private
private Microsoft.Office.Interop.Word.Application GetApp(out int processId)
    {
        //some code which returns Application

    }
</code></pre>

<p>Now I dont want to execute this method instead I want to shim this method 
using </p>

<pre><code>ShimMyclassName.Allinstances.set_GetAppInt32Out = () =&gt; my expected output
</code></pre>

<p>But compiler is throwing error:</p>

<pre><code>cannot assign to set_GetAppInt32Out because it's a method group.
</code></pre>

<p>So I tried to changed it to:</p>

<pre><code>ShimMyclassName.Allinstances.set_GetAppInt32Out( here it is expecting some out delegate like (OutFunc&lt;WordApplication, int, Microsoft.office.Interop.Word.Application&gt; Value)
</code></pre>

<p>In ShimMyClass below is the signature:
    public void set_GetAppInt32Out(object value);</p>

<p>So I'm stuck here. How can I pass the value and How I can Break the private method call and expect it to return my expected output instead of executing the original private method?</p>