Skip to main content

Structure of %UnitTest and xUnit Frameworks

The %UnitTest package and the xUnit frameworks share the same basic structure. A developer familiar with any of the xUnit frameworks will have no trouble learning to use the %UnitTest package. %UnitTest and the xUnit frameworks are all organized around the following basic testing structures:

  • Test Fixture — Code that does preparation and clean-up work for a test or set of tests. Preparation for a test might include creating database connections, or initializing a database with test data. Clean-up might include closing database connections or restoring the state of the database.

  • Test Case — The smallest unit of testing. Verifies that a particular set of inputs result in a particular output for a given module.

  • Test Suite — A collection of tests and test suites that are designed to be executed together.

  • Test Runner — A utility for executing tests and displaying their outcomes.

FeedbackOpens in a new window