title: Need a mock server for my custom HttpClient rest template to test with
body: <p>I have a custom authentication rest template my library returns which is HttpClient.  I need a library that will let me bind my rest template to the mock server so I can test my template.  I had high hopes for <a href="https://docs.microsoft.com/en-us/aspnet/core/test/integration-tests?view=aspnetcore-2.2" rel="nofollow noreferrer">TestServer</a> in .Net Core but  it has it's own <code>TestServer.CreateClient()</code> with special <code>HttpMessageHandler</code>.  Seems to be no way to use use my own rest template with that.  I use WireMock for some other basic canned request and response stuff but I really need to bind this template to my test server much like you would see in Java's MockRestSesrviceServer seen here.  <a href="https://www.baeldung.com/restclienttest-in-spring-boot" rel="nofollow noreferrer">https://www.baeldung.com/restclienttest-in-spring-boot</a> (section 2).  </p>
  
  <p>I've looked around a lot haven't found one that allow this type of binding in .NET Core.  I had high hopes for <a href="https://github.com/richardszalay/mockhttp" rel="nofollow noreferrer">mockhttp</a> but again, no way to bind with your own HttpClient it seems.  Have a missed it?  Is there a way to do this with TestServer or is there another lib out there I missed that will do this?  Thanks for any input.  It's been weeks on this.  </p>
  
  <p>I should mention this is lib/nuget package I'm working on so I don't have web startup classes built into the src project to test from.  I'd have to create anything  to seed webproject configs similar to a startup.cs, which Im willing to do if that will work.  </p>