public void T4() { IPerson person = Auto.Make <IPerson>().Object; var i = person.BasicMethod(1); Assert.That(person, Is.Not.Null); Assert.That(i, Is.Not.Null); Assert.That(i, Is.EqualTo("string")); }
public void T5() { Auto.Configure.With("Global Config"); IPerson person = Auto.Make <IPerson>().With("Instance Config").Object; var i = person.BasicMethod(1); Assert.That(person, Is.Not.Null); Assert.That(person.FirstName, Is.EqualTo("Instance Config")); // methods return values do not respect instance config, but do obey global config Assert.That(i, Is.EqualTo("Global Config")); }