Upgrading from V1.x to V2.x
Upgrading requires a minimal amount of work.
Since the framework still looks for test methods by name in addition
to the attributes, no test method will need to be modified to upgrade
to the new version. The only source code change required is to remove
the constructor with the string parameter in the class that inherits
from TestCase. The only new requirement is that you have a default constructor.
If there was significant processing in the existing constructor
than just move it to the default constructor. The only other change
is to change the reference to nunit.framework.dll instead of the
V1.x framework dll. Using the TestCase class has been
marked obsolete so you will get warnings, but they can be ignored
for now!
Suite property
The existing Suite property will not be found by the new program.
These must be changed to the "Suite" attribute for the
test runners to find them. Another alternative is that these suites
are no longer needed due to the automatic capability that is built
in to the new version.
AssertionFailedError
If you have written code expecting the exception AssertionFailedError,
this must be changed to AssertionException.
|