title: In C# Unit test how do equivalent of Java's Spy (instead of Mock) to only mock some methods on a class?
body: <p>In Java, when I have a class that calls some other class' static method, I always encapsulate this so I can test it without actually hitting that real resource. For example:</p>
  
  <pre><code>public class HasSomeStaticCall
  {
      public HasSomeStaticCall()
      {
          this.something = callStaticThing();
      }
  
      protected String callStaticThing()
      {
          return SomeThirdParty.getFromStaticMethod();
      {
  }
  </code></pre>
  
  <p>In Java, I can then use <code>Spy</code> instead of <code>Mock</code> and then use all the real methods except for that one.</p>
  
  <p>Example:</p>
  
  <pre><code>public void test()
  {
      HasSomeStaticCall obj = Mockito.spy( HasSomeStaticCall.class );
  
      //Only mock this one method
      Mockito.doReturn( "SomeValue" ).when( obj ).callStaticThing();
  }
  </code></pre>
  
  <p>How would I do this in C#? (I'm using the .Net Framework 4.7.x, <em>not</em> .Net Core) </p>