I know that this is about NUnit, and I do not want to argue about whether it is good or bad practice to test private members. The fact is that sometimes it is necessary, especially when you have to deal with outdated or poorly developed code that cannot be reorganized.
, Gallio/MbUnit API , .
: SomePrivateMethod foo.
[Test]
public void SampleTest()
{
var foo = new Foo();
int actual = Mirror.ForObject(foo)["SomePrivateMethod"].Invoke();
Assert.AreEqual(123, actual);
}