Moq It.IsAnyType not working for Func returning Task with generic type
问题 I've tried 3 different ways to setup a mock for a generic interface method. Only one way works, but it is using an explicit type, so won't work generically. I tried using It.IsAnyType, but it doesn't seem to match on the call that is made. Here is the sample code (I expected test case 1 to have "asdf" returned). How can I get the mock to work for any type (not just string?)? using Moq; using System; using System.Threading.Tasks; namespace blah { public class Junk : IGetOrAddable { public