Set up
Setup is very simple.
- Download NBehave from trunk or a release.
- If you downloaded the installer version, run installer to install nbehave.
- The installer doe not put anything into the gac, it will register the testdriven.net runner if you choose to install it.
- Installer also comes with examples, check them out.
- Add a reference to NBehave.Narrator.Framework.dll if you are writing text specifications.
- If you want to use nbehave's assert extensions for a test framework add reference to NBehave.Spec.dll and one the specific test framework you want to use, ex: nbehave.spec.nunit.dll. You must also reference the corresponding test framework dll(s), so if you added nbehave.spec.nunit.dll you must also reference nunit.framework.dll
- let your spec/example/test class inherit from SpcBase or SpecBase<T> ,ex: NBehave.Spec.NUnit.SpecBase
- override (if you want to) Establish_context() and Because_of()
- tag your spec methods with [Specification] or the test framework's attribute, ex [Test] for NUnit and MbUnit.
- Start writing specs.