I am new to NSubstitute and have previously worked with Moq. I want to call a function with any arguments and return an object that I create with any constructor args except one that I want to set.
In Moq i can write this:
new TestObject(It.IsAny<string>(), It.IsAny<bool>(), aValueIWantToControle)
In NSubstistute I tried:
var mySubstitute = Substitute.For<IMySubstitute>();
mySubstitute.DoSomething(Arg.Any<bool>(), Arg.Any<string>())
.Returns(new TestObject(Substitute.For<string>(), Substitute.For<bool>(), aValueIWantToControle));
How can i create an object like this in NSubstitute?