Griffin,
Here are some sketches of what I have in mind:
* DotNetMock.Assertion will be modified to "detect" frameworks if
the environment variables have not been set. The detection algorithm
will check for nunit.framework first to make it as backward compatible
as possible.
* The list of frameworks to detect will be pre-compiled/configured
in some global property like
AutoDetectTestFramework.SupportedFrameworks[].AssemblyName. It will
search in order for the (partial) assembly names like nunit.framework,
MbUnit.Core, csUnit
* It will then use the corresponding profile/stub-generator that
does the actual work of dynamically creating a class that implements
ITestFramework.
* It will instantiate an instance of that generated class and
assign it to Assertion._testFramework.
I'm also thinking about whether we should do some exception mapping as
well. Rethrowing everything as an AssertionException seems to lose
something.
Anyways, I'll branch off and let you know how it goes.
--Choy
|