Skip to content

Instantly share code, notes, and snippets.

@JamesBender
Created November 18, 2013 19:41
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save JamesBender/7534035 to your computer and use it in GitHub Desktop.
Save JamesBender/7534035 to your computer and use it in GitHub Desktop.
[TestFixture]
public class FutureMockingTests
{
[Test]
public void FutureTest()
{
var expectedDependency = Mock.Create<DependencyClass>();
Mock.Arrange(() => expectedDependency.GetDependentValue())
.IgnoreInstance()
.Returns(5);
var classUnderTest = new DependentClass();
Assert.AreEqual(5, classUnderTest.GetValue());
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment