Skip to content

Instantly share code, notes, and snippets.

@b1ff
Created April 28, 2014 16:06
Show Gist options
  • Save b1ff/11376468 to your computer and use it in GitHub Desktop.
Save b1ff/11376468 to your computer and use it in GitHub Desktop.
public class Test
{
private Fixture fixture;
private IRepository sut;
public Test()
{
fixture = new Fixture(); // with some configuration
sut = fixture.Freeze<IRepository>();
}
[Theory, NSubData]
public void nsubData_gets_the_same_fixture_instance([Frozen]IRepository repo)
{
repo.Should().BeSameAs(sut);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment