Xunit Setup -Ausnahme werfen


Mock<ISomeObj> someObj = new Mock<ISomeObj>();

//NOTE the Throws method
someObj.Setup(s => s.Get())
  .Throws(new IOException());
Upvote answer :-)